Completed
Details
Details
Assignee
Unassigned
UnassignedReporter
Alex Miller
Alex MillerLabels
Approval
Ok
Patch
Code
Priority

Affects versions
Fix versions
Created May 6, 2015 at 10:17 PM
Updated June 5, 2015 at 3:53 PM
Resolved June 5, 2015 at 3:53 PM
When moving from LazySeqs to the new types we lost this but I don't think we should. Tools like Cursive use this for deciding when and how much to realize from a lazy sequence.
Approach:
iterate - The head of an iterate will always have the seed value and return 1 realized value. Subsequent elements will start unrealized and then become realized when the iterate function has been invoked to produce the value.
cycle - Returns unrealized if _current has been forced (initially null for all nodes after the first node).
(Note that range and repeat effectively always have their first element realized so I have chosen not to implement IPending - there is no delayed computation pending.)
Patch: clj-1726-2.patch