On Friday 18 April 2008 13:42:01 [EMAIL PROTECTED] wrote: > Added: trunk/languages/lua/src/lib/bc.pir > =========================================================================== > --- (empty file) > +++ trunk/languages/lua/src/lib/bc.pir Fri Apr 18 13:42:00 2008
> +.sub 'get' :anon > + .param int narg > + .param pmc x :optional > + if null x goto L1 > + $I0 = isa x, 'LuaNumber' > + if $I0 goto L2 > + $I0 = isa x, 'LuaString' > + if $I0 goto L2 > + goto L1 > + L2: > + $S0 = x.'tostring'() > + new $P0, MYPMC > + set $P0, $S0 > + .return ($P0) > + L1: > + $P1 = lua_checkudata(narg, x, MYTYPE) > + .return ($P1) > +.end Does :anon conflict with :multi such that this can't be a :multi, or does :optional conflict with :multi? If this were my code, I'd try to get rid of that type check and dispatch. -- c