Coffin, Eric wrote: > Greg, > > How about another option: > > d) 666 + 42 + 42 + ke + ke > > Wouldn't that make more sense if the use of 'foo' and '\foo' were first > substituted with ke and then the body were further expanded? > > -Eric Yes, that's actually what I meant to write for (b), sorry. It's the next most sensible answer once escaped names are made secure. The power for a macro to invoke an actual argument as a macro looks nice in such a small example. Expanding `sna(ke+1) as 666 + 42+1 + 42+1 + ke+1 + ke+1 looks less appealing than 666 + 69 + 69 + ke+1 + ke+1 . My related question about the "tokenness" of `identifier also sets up the question of whether getting ` and ke together in this example doesn't perhaps require token gluing. If not, then can I: ` define foo tasking4it always begin ` foo( arg1, arg2 ); end task tasking4it( a, b ); ... endtask ? Greg Greg Jaxon wrote: > > `define \foo(3) 666 > `define sna(foo) `\foo(3) + `\foo + `foo + \foo + foo > `define foo 69 > `define ke 42 > > Does `sna(ke) expands to: > > a) 666 + 69 + 69 + ke + ke > b) `\ke(3) + `42 + `42 + 42 + 42 // with errors of course > c) `\ke(3) + `\ke + `42 + \ke + 42 // also errors > > > -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.Received on Tue Mar 4 14:04:48 2008
This archive was generated by hypermail 2.1.8 : Tue Mar 04 2008 - 14:05:13 PST