Diff
Not logged in

Differences From Artifact [99466484fdc29835]:

To Artifact [fe180b545227dcde]:


19 19 if x<y then y else x 20 20 }; 21 21 @macro maxGreat(x,y){@value( 22 22 var nx = gensym(); # generate fresh symbol 23 23 var ny = gensym(); 24 24 @macro _x = @macro(nx) {name: nx}; # cheating to create {is:"Var" .. } 25 25 @macro _y = @macro(ny) {name: ny}; # at macro layer 26 - {is: "Let", name: nx, layer: "", init: @macro(x), expr: 27 - {is: "Let", name: ny, layer: "", init: @macro(y), expr: 26 + {is: "Let", name: nx, layer: "", vdef: @macro(x), expr: 27 + {is: "Let", name: ny, layer: "", vdef: @macro(y), expr: 28 28 @macro(if _x < _y then _y else _x)}} # the expression 29 29 )}; 30 30 31 31 print( maxGood(print(1), print(2)) ); # 1 2 2 32 32 print( maxBad(print(1), print(2)) ); # 1 2 2 2 33 33 print( maxFun(print(1), print(2)) ); # 1 2 2 34 34 print( maxGreat(print(1), print(2)) ); # 1 2 2