specify call-by-need

Scott Turner 2haskell at pkturner.org
Wed Feb 16 04:59:39 CET 2011


On 2011-02-15 21:12, John Meacham wrote:
> Except for the fact that compilers don't actually implement call by
> need. An example would be the speculative evaluation of ghc.
An interesting option.  The things I've read say that it's not in the
released ghc.

> And local optimizations that affect asymptotic behavior are used all
> the time, to the point they are vital for a functioning compiler. The
> tail-call optimization turning O(n) space usage to O(1) being a prime
> example.
Yes, that's essential.

> I think that specifying call-by-need would be more confusing and
> contrary to what actually exists in the wild.
Agreed that it may be confusing to call it "call-by-need" when there are
several necessary exceptions.  Apart from the name, I would hope it's
possible to begin to tame this region of the Haskell spec.

    -- Scott Turner



More information about the Haskell-prime mailing list