Version française
Home     About     Download     Resources     Contact us    
Browse thread
Parameter evaluation order
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Hao-yang Wang <hywang@p...>
Subject: Re: Parameter evaluation order

>Suppose you want to evaluate a curried function call in left-to-right
>order:
>f e1 e2 e3 e4
>
>You must evaluate f first, then e1.  Then you must apply f to e1, giving
>a new function g1.  Then you must evalue e2, then apply f1 to e2, giving
>f2, etc.

It seems to me that as long as evaluate f the last, we are ok. We can 
specify the evaluation order of the _parameters_ left-to-right (i.e., e1 
then e2, e3, e4, and finally f), without running into the efficiency 
problem.

Cheers,
Hao-yang Wang