Apologies for joining the conversation so late: On 30 Jan 2007, at 07:23, Eric Blake wrote:
How about if M4 uses a slightly-different syntax, so that the two usesare never confused? That way, the conversion problem won't ever have to be addressed, and Autoconf won't have to disable the extension during a transition period.So, for example, suppose M4 uses the syntax ${{11}} to refer to argument 11? Or (if you prefer something shorter) ${+11}? An advantage to this sort of approach is that it gives you more leeway for future extensions.You have a reasonable point there. My current plan was to add new syntaxcategories that could be controlled through the changesyntax builtin(available in beta since at least 1.4o several years ago). So using $<1> instead of ${1} is easy - just use changesyntax([{<], [}>]) up front in m4sugar. On the other hand, supporting a multi-character delimiter thatis still selectable by the m4 user is a bit tougher; I would need to introduce a new macro similar to changequote and changecom (perhaps changeextarg({{, }}) for choosing ${{1}} to mean an m4-parsed extended argument, leaving ${1} for literal output).
The intention with m4-2.0 and beyond was to make the rescanning enginebecome modular enough that it would be possible to select a ``language''.
For example we already have 3 such languages (albeit implemented outside the current module system): traditional, gnu, and posix. Ultimately, we should freeze core parsing issues to make an ``autoconf'' language, which autoconf-3.0 could extend with modules it chose to ship. Also, I'd like to have an m5 language (Prof Dain Samples extended m4), and to split gnu into gnu-m4 (1.4.x syntax) and gnu-m42 (2.0 extensions). Considering how little time I've had for gnu recently, I think it is fine to push these ideas out past the 2.0 release, though the default configuration of m4-2.0 (and beyond) should be fully compatible with m4-1.4 -- any syntax improvements or extensions are the remit of gnu-m42. Cheers, Gary -- ())_. Email me: [EMAIL PROTECTED] ( '/ Read my blog: http://blog.azazil.net / )= ...and my book: http://sources.redhat.com/autobook `(_~)_ Join my AGLOCO Network: http://www.agloco.com/r/BBBS7912
PGP.sig
Description: This is a digitally signed message part
_______________________________________________ M4-discuss mailing list M4-discuss@gnu.org http://lists.gnu.org/mailman/listinfo/m4-discuss