id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc	os	architecture	failure	difficulty	testcase	blockedby	blocking	related
1219	RULE for take is too strict	simonpj	igloo	"{{{
main = print (map (const 'x') (take 1 (undefined:undefined)))
}}}
In ghci, or with ghc -O0, this produces `""x""`. With ghc -O, this produces `Prelude.undefined`.  Kirsten Chevalier found that the culprit is the RULE:
{{{
""take""     [~1] forall n xs . take n xs 
    = case n of I# n# -> build (\c nil -> foldr (takeFB c nil) 
                                                (takeConst nil) xs n#)
}}}
This rule makes `take` strict in `xs`, but it should be lazy when `n`=0."	merge	closed	normal	6.6.1	libraries/base	6.6	fixed			Unknown/Multiple	Unknown/Multiple		Easy (less than 1 hour)				
