M4 String Functions + Macro Expansion

2004-12-16 Thread Noah Misch
How does one coax a string macro into considering a string, expanded? Consider this macro: # Foo(EXPRESSION) # --- # Emit expression with the right prologue. m4_define([Foo], [m4_bregexp([$1], [special], [Special prologue.])[]dnl $1]) For maximum user flexibility, the emitted copy of

Re: M4 String Functions + Macro Expansion

2004-12-16 Thread Bruce Korb
Paul Eggert wrote: > > Akim Demaille <[EMAIL PROTECTED]> writes: > > "Noah" == Noah Misch <[EMAIL PROTECTED]> writes: > > > > > I hope I have missed a general solution. Ideas? > > > > Fix m4. > > Or switch to a different scripting language. That'd be a lot of work > too, unfortunately...

Re: M4 String Functions + Macro Expansion

2004-12-16 Thread Paul Eggert
Akim Demaille <[EMAIL PROTECTED]> writes: "Noah" == Noah Misch <[EMAIL PROTECTED]> writes: > > > I hope I have missed a general solution. Ideas? > > Fix m4. Or switch to a different scripting language. That'd be a lot of work too, unfortunately __

Re: M4 String Functions + Macro Expansion

2004-12-16 Thread Akim Demaille
>>> "Noah" == Noah Misch <[EMAIL PROTECTED]> writes: > I hope I have missed a general solution. Ideas? Fix m4. It has fundamental flaws from its inception: - text processing builtins (regexp etc.) should return quoted strings, they do not. - eval should do what it does it almost all the ot