Well I certainly hope the standard defines that both fred and bob will only be evaluated once, because my programs depend on that :)
Peter Neil wrote: > fred = 2 + 2 > bob = fred + fred > In a Haskell implementation fred would be evaluated once to 4, then > used twice. The 2+2 would only happen once (ignore defaulting and > overloaded numerics for now). > Is this sharing mandated by the standard? (I don't think so) Is there > some paper that describes why this is desirable, and gives any detail? > Do all Haskell compilers support the sharing? _______________________________________________ Haskell-Cafe mailing list [email protected] http://www.haskell.org/mailman/listinfo/haskell-cafe
