Opened 7 years ago

Closed 7 years ago

#55 closed defect (wontfix)

Lazy evaluation

Reported by: cowan Owned by: alexshinn
Priority: major Milestone:
Component: WG1 - Core Keywords:


R5RS provides a simple mechanism for easy cases of lazy evaluation. It does not support generalized lazy evaluation, because all built-in procedures are eager whether they 'need' to be or not. The relevant identifiers are delay and force; they are not present in IEEE Scheme. SRFI 45 argues that this pair is insufficient for expressing common lazy algorithms in a way that preserves tail recursion, and adds lazy (equivalent to (delay (force ...)), but acting atomically) and eager. The semantics of delay and force remain downward compatible.

Change History (4)

comment:1 Changed 7 years ago by cowan

I favor the SRFI 45 argument; see the SRFI itself for details.

I think the four identifiers should be in an optional module.

Editorial note: the sample implementation given in R4RS and R5RS does not conform to the specification (it doesn't memoize) and should be removed or replaced.

comment:2 Changed 7 years ago by cowan

  • Component changed from WG2 - Base Library to WG1 - Core
  • Owner changed from cowan to alexshinn

comment:3 Changed 7 years ago by alexshinn

Regarding the sample implementation from R5RS, it does
memoize via make-promise so there's no need to change it.

comment:4 Changed 7 years ago by cowan

  • Resolution set to wontfix
  • Status changed from new to closed

WG1 voted to reject SRFI 55.

Note: See TracTickets for help on using tickets.