On Mon, Apr 14, 2008 at 5:03 AM, Klaas-Jan Stol <[EMAIL PROTECTED]> wrote:
> IMCC's macro processor doesn't currently allow for uniquely generated
>  variable names. It's in the pdd (19), but not yet implemented.
>
>  You're right in that it only works for labels.
>
>  kjs
>
>
>
>
>  On Mon, Apr 14, 2008 at 1:32 PM, François Perrad
>  <[EMAIL PROTECTED]> wrote:
>  >
>  >  In Lua libraries, I wrote many time the same piece of code.
>  >  The purpose of this code is to register each function.
>  >  So, I try to write the following PIR macro :
>  >
>  >         .macro register(tname, fname)
>  >             .const .Sub $fname = .fname
>  >             $fname.'setfenv'(_lua__GLOBAL)
>  >             set $P1, .fname
>  >             .tname[$P1] = $fname
>  >         .endm
>  >
also note that .Sub is deprecated, and should be replaced by 'Sub'
~jerry

Reply via email to