[plt-scheme] call-by-value vs. call-by-name?

From: Matthias Felleisen (matthias at ccs.neu.edu)
Date: Tue Jan 29 11:31:50 EST 2008

On Jan 28, 2008, at 2:08 PM, Shu-yu Guo wrote:

> On 1/28/08, Grant Rettke <grettke at acm.org> wrote:
>> On the fringes of the professional community (blogs posting and
>> articles), there has been a lot of hype about Haskell for the past
>> year or two. So much so that 'functional programming' and 'lazy'
>> seemingly go together like 'peanut butter and jelly'.
> I don't think this is anything new -- people seemed to have considered
> laziness "crucial" to FP for a while. John Hughes in his 1984 memo
> lists it as one of the reasons why FP matters at all.

Once again, the idea that everything ought to be lazy has been  
debunked, see FPCA 1995. The quick summary is that if you look at any  
large code basis you realize that you definitely do want lazy  
constructors but lazy functions is an entirely different thing. As  
far as I can tell, people who are willing to look at this from a  
reasonably neutral effort have come to agree that the examples that  
demonstrate the need for lazy functions are toy examples. Put  
positively, you do want

   -- cbv functions
   -- eager constructors
   -- and lazy constructors

;; ---

 From a rather personal perspective: I was convinced that  
continuation objects were a necessary ingredient of a good mostly  
functional language and that we needed to spend a serious amount of  
research on it. Unfortunately, I did. Fortunately, I always kept in  
mind that doing so would teach me general tricks for formulating  
semantic models and that part paid off. The best thing I ever did was  
to admit that continuations are cute, but that they just don't  
deserve the energy I had spent on them and to move on.

PLT Scheme's continuations are just good enough until someone proves  
me wrong with a solid SE case.

-- Matthias

Posted on the users mailing list.