-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to Peter O'Gorman on 8/15/2008 9:09 AM:
> 
> Having a #define in an AH_VERBATIM/AH_TOP/AH_BOTTOM block gives
> undefined behavior? I'm not sure that there are many
> AH_VERBATIM/AH_TOP/AH_BOTTOM blocks without a #define, certainly very
> few that I have written :(

Hmm.  Gnulib has its fair share of AH_VERBATIM that use #define.  And your
argument for why #define is needed makes sense.

On rereading what was recently patched, the section on Header Templates
states "The use of `#define' instead of `#undef', or of comments on the
same line as `#undef', is strongly discouraged."
http://git.savannah.gnu.org/gitweb/?p=autoconf.git;a=commitdiff;h=6d04538

Then it mentions autoheader as an alternative to maintaining config.h.in
by hand.  And in the Autoheader Macros node, it states "Please note that
`text' gets included ``verbatim'' to the template file, not to the
resulting config header, so it can easily get mangled when the template is
processed." (although that statement is under AH_BOTTOM rather than
directly tied to AH_VERBATIM).  But it states nothing about whether
#define runs the risk of being mangled.

Sounds like we need a follow-up doc patch; anyone care to write a first
draft?  Ralf, you are more familiar with the current state of
config.status code than me; are we sure that only #undef patterns in the
template file are modified, and that #define is intended to make it
through AH_VERBATIM unmolested?  Is the testsuite sufficiently testing this?

At any rate, you've overcome my two (non-)nits by good argumentation, and
I think your patch is ready.  Please push, or let me know if I need to help.

- --
Don't work too hard, make some time for fun as well!

Eric Blake             [EMAIL PROTECTED]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkimTzwACgkQ84KuGfSFAYAG6wCgxsK1blHyJwDX8UqzF4u/Ygs8
gyMAoJxU9gwwa/c8RAnyRj+B8xxowu92
=GDIQ
-----END PGP SIGNATURE-----


Reply via email to