Passing lazy parmeters to functions that take lazy parameters

Walter Bright newshound at digitalmars.com
Mon Sep 4 15:21:01 PDT 2006


Joe Gottman wrote:
> Suppose I have a function f that has a lazy parameter x, and I pass it into 
> another function g that has a lazy parameter.  Will x be evaluated when it 
> is passed to g?

No, it isn't evaluated. The evaluation of it is wrapped up into another 
delegate and passed to g.



More information about the Digitalmars-d mailing list