|
From: Alex S. <ss...@mw...> - 2013-01-16 10:24:26
|
On 2013/01/15 03:04 PM, Alexander S.Kresin wrote:
> It looks interesting for me. We could add this clause to all our
> commands, but I can't make it to work - it gives errors while
> compiling. And what is the __IIF ?
Sorry, I did not give you the complete code, here is a minimal example
with all that is required:
#xtranslate __IIF(.T., [<true>], [<false>]) => <true>
#xtranslate __IIF(.F., [<true>], [<false>]) => <false>
#xcommand JOINSTR <a>, <b> [ <fcn: FCN> <fcnname> ] => ;
__IIF(<.fcn.>, <fcnname>, Join)(<a>, <b>)
procedure main
JOINSTR "a", "b"
JOINSTR "a", "b" FCN MyJoin
return
procedure Join(a, b)
? a + b
procedure MyJoin(a, b)
? a + ", " + b
--
Regards
Alex
|