autoconf-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: preparation for expand-before-require warning


From: Paolo Bonzini
Subject: Re: preparation for expand-before-require warning
Date: Wed, 21 Jan 2009 09:01:30 +0100
User-agent: Thunderbird 2.0.0.19 (Macintosh/20081209)

> m4_defun([a],[A])
> m4_defun([b],[m4_require([a])B])
> m4_defun([c],[a
> b])

I still think that c should require both a and b, IOW all zero-argument
macros should be designed so that they can be required, but that's a way
more radical change.  Maybe another warning, enabled only with a more
specific option, would be a good idea.

> is rather common (autoconf, automake, and gnulib all triggered it, and gnulib 
> in multiple places), but is also harmless (you can't get out-of-order 
> expansion 
> from an ac_require until you have _nested_ ac_require).  So I reworked my 
> patch 
> to recognize this case and avoid treating it as a false positive,

Both patches look like the correct approach; can you add a couple of
lines to the documentation of the require mechanism in m4sugar.m4?

Paolo




reply via email to

[Prev in Thread] Current Thread [Next in Thread]