mirror of
git://git.sv.gnu.org/autoconf
synced 2025-01-06 10:25:53 +08:00
m4sh: reduce size of AS_VAR_TEST_SET
* lib/m4sugar/m4sh.m4 (AS_VAR_TEST_SET): Make more compact. Signed-off-by: Eric Blake <eblake@redhat.com>
This commit is contained in:
parent
bbf53dd459
commit
ae1cc9f03f
@ -1,5 +1,8 @@
|
||||
2010-08-25 Eric Blake <eblake@redhat.com>
|
||||
|
||||
m4sh: reduce size of AS_VAR_TEST_SET
|
||||
* lib/m4sugar/m4sh.m4 (AS_VAR_TEST_SET): Make more compact.
|
||||
|
||||
tests: improve some shell assumption testing
|
||||
* tests/m4sh.at (Functions Support, Functions and return Support)
|
||||
(Negated classes in globbing): Update comments.
|
||||
|
@ -2063,13 +2063,13 @@ m4_define([AS_VAR_SET_IF],
|
||||
|
||||
# AS_VAR_TEST_SET(VARIABLE)
|
||||
# -------------------------
|
||||
# Expands into the `test' expression which is true if VARIABLE
|
||||
# Expands into an expression which is true if VARIABLE
|
||||
# is set. Polymorphic.
|
||||
m4_define([AS_VAR_TEST_SET],
|
||||
[AS_LITERAL_WORD_IF([$1],
|
||||
[test "${$1+set}" = set],
|
||||
[{ as_var=$1; eval "test \"\${$as_var+set}\" = set"; }],
|
||||
[eval "test \"\${$1+set}\"" = set])])
|
||||
[${$1+:} false],
|
||||
[{ as_var=$1; eval \${$as_var+:} false; }],
|
||||
[eval \${$1+:} false])])
|
||||
|
||||
|
||||
## -------------------- ##
|
||||
|
Loading…
Reference in New Issue
Block a user