<< Back to previous view

[CLJ-1160] reducers/mapcat ignores Reduced Created: 11/Feb/13  Updated: 01/Mar/13

Status: Open
Project: Clojure
Component/s: None
Affects Version/s: Release 1.5
Fix Version/s: Release 1.6

Type: Defect Priority: Major
Reporter: Christophe Grand Assignee: Christophe Grand
Resolution: Unresolved Votes: 1
Labels: None

Attachments: File lazy-rmapcat.diff    
Patch: Code and Test

 Description   

The following code throws an exception:

(->> (concat (range 100) (lazy-seq (throw (Exception. "Too eager"))))
(r/mapcat (juxt inc str))
(r/take 5)
(into []))

This is because r/mapcat introduces an intermediate reduce which swallows the reduced value coming from r/take.


Generated at Sat May 25 19:35:07 CDT 2013 using JIRA 4.4#649-r158309.