mirror of
git://git.sv.gnu.org/autoconf
synced 2024-12-03 02:00:36 +08:00
Fix underquotation in AS_HELP_STRING.
* lib/m4sugar/m4sh.m4 (AS_HELP_STRING): Don't underquote lhs argument. * lib/m4sugar/m4sugar.m4 (m4_text_wrap): Don't underquote first-prefix argument. * tests/m4sh.at (AS@&t@_HELP_STRING): Test this fix. * NEWS: Document AS_HELP_STRING fix. Signed-off-by: Eric Blake <ebb9@byu.net>
This commit is contained in:
parent
3b121ee688
commit
f444a9fa8e
@ -1,5 +1,13 @@
|
|||||||
2007-09-27 Eric Blake <ebb9@byu.net>
|
2007-09-27 Eric Blake <ebb9@byu.net>
|
||||||
|
|
||||||
|
Fix underquotation in AS_HELP_STRING.
|
||||||
|
* lib/m4sugar/m4sh.m4 (AS_HELP_STRING): Don't underquote lhs
|
||||||
|
argument.
|
||||||
|
* lib/m4sugar/m4sugar.m4 (m4_text_wrap): Don't underquote
|
||||||
|
first-prefix argument.
|
||||||
|
* tests/m4sh.at (AS@&t@_HELP_STRING): Test this fix.
|
||||||
|
* NEWS: Document AS_HELP_STRING fix.
|
||||||
|
|
||||||
Autotest formatting touchups.
|
Autotest formatting touchups.
|
||||||
* lib/autotest/general.m4 (HELP_TUNING): Avoid TAB in terminal
|
* lib/autotest/general.m4 (HELP_TUNING): Avoid TAB in terminal
|
||||||
output.
|
output.
|
||||||
|
2
NEWS
2
NEWS
@ -38,6 +38,8 @@ GNU Autoconf NEWS - User visible changes.
|
|||||||
|
|
||||||
** AC_USE_SYSTEM_EXTENSIONS now defines _ALL_SOURCE for Interix platforms.
|
** AC_USE_SYSTEM_EXTENSIONS now defines _ALL_SOURCE for Interix platforms.
|
||||||
|
|
||||||
|
** AS_HELP_STRING no longer underquotes its first argument.
|
||||||
|
|
||||||
** The command 'autoconf -' now correctly processes a file from stdin.
|
** The command 'autoconf -' now correctly processes a file from stdin.
|
||||||
|
|
||||||
** Autotest now determines $srcdir correctly.
|
** Autotest now determines $srcdir correctly.
|
||||||
|
@ -1205,7 +1205,7 @@ m4_define([AS_HELP_STRING],
|
|||||||
[m4_pushdef([AS_Prefix], m4_default([$3], [ ]))dnl
|
[m4_pushdef([AS_Prefix], m4_default([$3], [ ]))dnl
|
||||||
m4_pushdef([AS_Prefix_Format],
|
m4_pushdef([AS_Prefix_Format],
|
||||||
[ %-]m4_eval(m4_len(AS_Prefix) - 3)[s ])dnl [ %-23s ]
|
[ %-]m4_eval(m4_len(AS_Prefix) - 3)[s ])dnl [ %-23s ]
|
||||||
m4_text_wrap([$2], AS_Prefix, m4_format(AS_Prefix_Format, [$1]))dnl
|
m4_text_wrap([$2], AS_Prefix, m4_format(AS_Prefix_Format, [[$1]]))dnl
|
||||||
m4_popdef([AS_Prefix_Format])dnl
|
m4_popdef([AS_Prefix_Format])dnl
|
||||||
m4_popdef([AS_Prefix])dnl
|
m4_popdef([AS_Prefix])dnl
|
||||||
])# AS_HELP_STRING
|
])# AS_HELP_STRING
|
||||||
|
@ -1576,16 +1576,16 @@ m4_define([m4_text_wrap],
|
|||||||
[m4_pushdef([m4_Prefix], [$2])dnl
|
[m4_pushdef([m4_Prefix], [$2])dnl
|
||||||
m4_pushdef([m4_Prefix1], m4_default([$3], [m4_Prefix]))dnl
|
m4_pushdef([m4_Prefix1], m4_default([$3], [m4_Prefix]))dnl
|
||||||
m4_pushdef([m4_Width], m4_default([$4], 79))dnl
|
m4_pushdef([m4_Width], m4_default([$4], 79))dnl
|
||||||
m4_pushdef([m4_Cursor], m4_qlen(m4_Prefix1))dnl
|
m4_pushdef([m4_Cursor], m4_qlen(m4_defn([m4_Prefix1])))dnl
|
||||||
m4_pushdef([m4_Separator], [])dnl
|
m4_pushdef([m4_Separator], [])dnl
|
||||||
m4_Prefix1[]dnl
|
m4_defn([m4_Prefix1])[]dnl
|
||||||
m4_if(m4_eval(m4_qlen(m4_Prefix1) > m4_len(m4_Prefix)),
|
m4_if(m4_eval(m4_qlen(m4_defn([m4_Prefix1])) > m4_len(m4_Prefix)),
|
||||||
1, [m4_define([m4_Cursor], m4_len(m4_Prefix))
|
1, [m4_define([m4_Cursor], m4_len(m4_Prefix))
|
||||||
m4_Prefix],
|
m4_Prefix],
|
||||||
m4_if(m4_eval(m4_qlen(m4_Prefix1) < m4_len(m4_Prefix)),
|
m4_if(m4_eval(m4_qlen(m4_defn([m4_Prefix1])) < m4_len(m4_Prefix)),
|
||||||
[0], [],
|
[0], [],
|
||||||
[m4_define([m4_Cursor], m4_len(m4_Prefix))[]dnl
|
[m4_define([m4_Cursor], m4_len(m4_Prefix))[]dnl
|
||||||
m4_for(m4_Space, m4_qlen(m4_Prefix1), m4_eval(m4_len(m4_Prefix) - 1),
|
m4_for(m4_Space, m4_qlen(m4_defn([m4_Prefix1])), m4_eval(m4_len(m4_Prefix) - 1),
|
||||||
[], [ ])])[]dnl
|
[], [ ])])[]dnl
|
||||||
)[]dnl
|
)[]dnl
|
||||||
m4_foreach_w([m4_Word], [$1],
|
m4_foreach_w([m4_Word], [$1],
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
AT_BANNER([M4sh.])
|
AT_BANNER([M4sh.])
|
||||||
|
|
||||||
# Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software
|
# Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software
|
||||||
# Foundation, Inc.
|
# Foundation, Inc.
|
||||||
#
|
#
|
||||||
# This program is free software: you can redistribute it and/or modify
|
# This program is free software: you can redistribute it and/or modify
|
||||||
@ -533,6 +533,18 @@ echo "AS_HELP_STRING([--foo@<][:@=bar@:][>@123456789012],
|
|||||||
[some other @<][:@ex@:][>@ which should wrap at our default of 80 characters.])"
|
[some other @<][:@ex@:][>@ which should wrap at our default of 80 characters.])"
|
||||||
echo "AS_HELP_STRING([--foo@<][:@=bar@:][>@1234567890123],
|
echo "AS_HELP_STRING([--foo@<][:@=bar@:][>@1234567890123],
|
||||||
[some other @<][:@ex@:][>@ which should wrap at our default of 80 characters.])"
|
[some other @<][:@ex@:][>@ which should wrap at our default of 80 characters.])"
|
||||||
|
echo "AS_HELP_STRING([[--foo[=bar]]],
|
||||||
|
[some other t[]t which should wrap at our default of 80 characters.])"
|
||||||
|
echo "AS_HELP_STRING([[--foo[=bar]123456789]],
|
||||||
|
[some other t[]t which should wrap at our default of 80 characters.])"
|
||||||
|
echo "AS_HELP_STRING([[--foo[=bar]1234567890]],
|
||||||
|
[some other t[]t which should wrap at our default of 80 characters.])"
|
||||||
|
echo "AS_HELP_STRING([[--foo[=bar]12345678901]],
|
||||||
|
[some other t[]t which should wrap at our default of 80 characters.])"
|
||||||
|
echo "AS_HELP_STRING([[--foo[=bar]123456789012]],
|
||||||
|
[some other t[]t which should wrap at our default of 80 characters.])"
|
||||||
|
echo "AS_HELP_STRING([[--foo[=bar]1234567890123]],
|
||||||
|
[some other t[]t which should wrap at our default of 80 characters.])"
|
||||||
]])
|
]])
|
||||||
|
|
||||||
AT_CHECK_M4SH
|
AT_CHECK_M4SH
|
||||||
@ -575,6 +587,19 @@ AT_CHECK([./script], [0],
|
|||||||
--foo[=bar]1234567890123
|
--foo[=bar]1234567890123
|
||||||
some other [ex] which should wrap at our default of
|
some other [ex] which should wrap at our default of
|
||||||
80 characters.
|
80 characters.
|
||||||
|
--foo[=bar] some other t[]t which should wrap at our default of
|
||||||
|
80 characters.
|
||||||
|
--foo[=bar]123456789 some other t[]t which should wrap at our default of
|
||||||
|
80 characters.
|
||||||
|
--foo[=bar]1234567890 some other t[]t which should wrap at our default of
|
||||||
|
80 characters.
|
||||||
|
--foo[=bar]12345678901 some other t[]t which should wrap at our default of
|
||||||
|
80 characters.
|
||||||
|
--foo[=bar]123456789012 some other t[]t which should wrap at our default of
|
||||||
|
80 characters.
|
||||||
|
--foo[=bar]1234567890123
|
||||||
|
some other t[]t which should wrap at our default of
|
||||||
|
80 characters.
|
||||||
]])
|
]])
|
||||||
|
|
||||||
AT_CLEANUP
|
AT_CLEANUP
|
||||||
|
Loading…
Reference in New Issue
Block a user