
30 Jun
2009
30 Jun
'09
4:29 p.m.
On Mon, Jun 29, 2009 at 11:30 PM, Ryan Ingram
There can't be a way to do so that is pure, because such a function could distinguish between
xs1 = () : xs1 and xs2 = f () where f () = () : f ()
But doesn't seq and friends cause many of our normal referential transparency guarantees to be invalid? Are you certain that claim holds in the presence of seq? As a side note, (allowing seq and unsafePerformIO if necessary) is it possible to implement a map that preserves cycles (instead of transparently replacing them with infinite copies? Not horribly useful, but would be quite cute. AHH