On Mar 17, 2009, at 6:15 , [email protected] wrote:

#macro( call $foo )#if($foo)#**##end#end
...
#call( $list.add("a").add("b") )
...

I believe the #if is minimally more economic than a #set, and for sure does not pollute the context namespace. Also the #**# was for a small bug in 1.4, where the if-block failed parse if it was empty.

If by economic you mean performant, I would argue that #set is probably faster. However, your call macro is a more general solution. Another possibility:

#set($list = $list.add("a").add("b"))


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to