]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
* lib/m4sugar/m4sh.m4 (_AS_QUOTE): The warning about quoted
authorAkim Demaille <akim@epita.fr>
Tue, 22 Oct 2002 08:20:19 +0000 (08:20 +0000)
committerAkim Demaille <akim@epita.fr>
Tue, 22 Oct 2002 08:20:19 +0000 (08:20 +0000)
characters is a syntax warning now.
(_AS_QUOTE): Accept $2 as list of characters to quote.
* lib/autoconf/autoheader.m4 (AH_VERBATIM, _AH_VERBATIM_OLD):
Quote for Perl, not sh.
* bin/autoheader.in: When $debug, report the file which is
`do'ne.
* tests/tools.at (autom4te, autoheader): Exercise @bar, not merely
`@', to tickle Perl's lists.
Reported by Carlos Velasco.

ChangeLog
THANKS
bin/autoheader.in
lib/autoconf/autoheader.m4
lib/m4sugar/m4sh.m4
tests/tools.at

index 58c60ce6a44c89b25ab6a8c2345b88270523995d..d1b9411a53e8e448dec432605a84075bc26f90ed 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,16 @@
+2002-10-22  Akim Demaille  <akim@epita.fr>
+
+       * lib/m4sugar/m4sh.m4 (_AS_QUOTE): The warning about quoted
+       characters is a syntax warning now.
+       (_AS_QUOTE): Accept $2 as list of characters to quote.
+       * lib/autoconf/autoheader.m4 (AH_VERBATIM, _AH_VERBATIM_OLD):
+       Quote for Perl, not sh.
+       * bin/autoheader.in: When $debug, report the file which is
+       `do'ne.
+       * tests/tools.at (autom4te, autoheader): Exercise @bar, not merely
+       `@', to tickle Perl's lists.
+       Reported by Carlos Velasco.
+
 2002-10-18  Akim Demaille  <akim@epita.fr>
 
        * bin/autom4te.in (handle_m4): Pass --fatal-warning to m4, so that
diff --git a/THANKS b/THANKS
index ec878fbd09951ed2dee87c03a9d1c8931803cfdc..b8d3019d65fbdd58b8c72db70d8ccecdd6272948 100644 (file)
--- a/THANKS
+++ b/THANKS
@@ -30,6 +30,7 @@ Bob Wilson                  bwilson@tensilica.com
 Bram Moolenaar              bram@vim.org
 Bruno Haible                haible@ilog.fr
 Carl Edman                  cedman@princeton.edu
+Carlos Velasco              carlosev@newipnet.com
 Chad R. Larson              chad@anasazi.com
 Chris P. Ross               cross@uu.net
 Chris Provenzano            proven@cygnus.com
index 60099f36317d2e1f5717bce85d37684c2d46b92e..e3440b4d4969efeef7820b301663cfbec92e5ae1 100644 (file)
@@ -176,6 +176,7 @@ xsystem ("$autoconf "
         . " $ARGV[0] >$tmp/traces.pl");
 
 local (%verbatim, %symbol);
+debug "$me: \`do'ing $tmp/traces.pl:\n" . `sed 's/^/| /' $tmp/traces.pl`;
 do "$tmp/traces.pl";
 warn "couldn't parse $tmp/traces.pl: $@" if $@;
 error "error: AC_CONFIG_HEADERS not found in $ARGV[0]"
index d60b0bda986c1928f41d9ac3799326c07317c7a9..e78d4c72472f3e3a62ab350627c3a71068f4605f 100644 (file)
@@ -64,18 +64,22 @@ m4_define([AH_OUTPUT], [])
 # may occur if there is AC_CHECK_FUNCS($my_func)), issue an autoheader
 # TEMPLATE associated to the KEY.  Otherwise, do nothing.  TEMPLATE is
 # output as is, with no formatting.
+#
+# Quote for Perl "" strings, which are those used by Autoheader.
 m4_define([AH_VERBATIM],
 [AS_LITERAL_IF([$1],
-               [AH_OUTPUT([$1], AS_ESCAPE([[$2]]))])
+               [AH_OUTPUT([$1], AS_ESCAPE([[$2]], [\"@$]))])
 ])
 
 
 # _AH_VERBATIM_OLD(KEY, TEMPLATE)
 # -------------------------------
 # Same as above, but with bugward compatibility.
+#
+# Quote for Perl "" strings, which are those used by Autoheader.
 m4_define([_AH_VERBATIM_OLD],
 [AS_LITERAL_IF([$1],
-               [AH_OUTPUT([$1], _AS_QUOTE([[$2]]))])
+               [AH_OUTPUT([$1], _AS_QUOTE([[$2]], [\"@$]))])
 ])
 
 
index e76818651e0fc711591b0fbfd29c4d526967b2e1..a77d848678e70b96cbc76b057dad8cea14d09a11 100644 (file)
@@ -335,18 +335,15 @@ m4_define([_AS_ECHO_UNQUOTED],
 [echo "$1" >&m4_default([$2], [AS_MESSAGE_FD])])
 
 
-# _AS_QUOTE(STRING)
-# -----------------
+# _AS_QUOTE(STRING, [CHARS = `"])
+# -------------------------------
 # If there are quoted (via backslash) backquotes do nothing, else
 # backslash all the quotes.
-# FIXME: In a distant future (2.51 or +), this warning should be
-# classified as `syntax'.  It is classified as `obsolete' to ease
-# the transition (for Libtool for instance).
 m4_define([_AS_QUOTE],
 [_AS_QUOTE_IFELSE([$1],
-                  [AS_ESCAPE([$1], [`""])],
-                  [m4_warn([obsolete],
-           [back quotes and double quotes should not be escaped in: $1])dnl
+                  [AS_ESCAPE([$1], m4_default([$2], [`""]))],
+                  [m4_warn([syntax],
+           [back quotes and double quotes must not be escaped in: $1])dnl
 $1])])
 
 
index bd89dd08a71caa1f7ea93f48699f0bbb3a2dfb0d..f8e6ce8084091681e1b001a699e0b81df4c5a5ce 100644 (file)
@@ -166,7 +166,7 @@ TRACE1
 TRACE2
 
 # With arguments, single line.
-TRACE1(foo, bar, baz)
+TRACE1(foo, @bar, @baz)
 TRACE1(foo, TRACE1(bar, baz))
 TRACE1(foo, active, baz)
 TRACE1(foo, [active], TRACE1(active, [active]))
@@ -183,8 +183,8 @@ AT_CHECK_AUTOCONF([-t TRACE1 -t TRACE2], 0,
 [[configure.ac:6:TRACE1:
 configure.ac:6:TRACE2:
 configure.ac:7:TRACE2:
-configure.ac:10:TRACE1:foo:bar:baz
-configure.ac:10:TRACE2:bar:baz
+configure.ac:10:TRACE1:foo:@bar:@baz
+configure.ac:10:TRACE2:@bar:@baz
 configure.ac:11:TRACE1:bar:baz
 configure.ac:11:TRACE2:baz
 configure.ac:11:TRACE1:foo::baz
@@ -205,7 +205,7 @@ AT_CHECK_AUTOCONF([[-t TRACE1:'
 [[
 [], [], [].
 
-[foo], [bar], [baz].
+[foo], [@bar], [@baz].
 
 [bar], [baz], [].
 
@@ -226,7 +226,7 @@ foo], [].
 AT_CHECK_AUTOCONF([-t TRACE2:'${)===(}@'], 0,
 [[[]
 []
-[bar])===([baz]
+[@bar])===([@baz]
 [baz]
 [])===([baz]
 [ACTIVE])===([baz]
@@ -458,14 +458,14 @@ AT_DATA([configure.ac],
 AC_CONFIG_HEADERS(config.h:config.hin)
 AH_TOP([Top1 from configure.ac.])
 AH_TOP([Top2 from configure.ac.])
-AH_TOP([The Cat in a @.])
+AH_TOP([The Cat in a h@t.])
 AH_VERBATIM([Middle], [Middle from configure.ac.])
-AH_VERBATIM([Mouse],  [The Mouse in a @.])
+AH_VERBATIM([Mouse],  [The Mouse in a h@t.])
 AH_BOTTOM([Bottom1 from configure.ac.])
 AH_BOTTOM([Bottom2 from configure.ac.])
-AH_BOTTOM([The Dog in a @.])
+AH_BOTTOM([The Dog in a h@t.])
 
-AC_DEFINE([ANT], [@], [The Ant in a @.])
+AC_DEFINE([ANT], [@], [The Ant in a h@t.])
 ]])
 
 
@@ -484,14 +484,14 @@ Top1 from configure.ac.
 
 Top2 from configure.ac.
 
-The Cat in a @.
+The Cat in a h@t.
 
-/* The Ant in a @. */
+/* The Ant in a h@t. */
 #undef ANT
 
 Middle from configure.ac.
 
-The Mouse in a @.
+The Mouse in a h@t.
 
 /* Define to the address where bug reports for this package should be sent. */
 #undef PACKAGE_BUGREPORT
@@ -512,7 +512,7 @@ Bottom1 from configure.ac.
 
 Bottom2 from configure.ac.
 
-The Dog in a @.
+The Dog in a h@t.
 /* Bottom from acconfig.h. */
 ]])