mirror of
git://git.sv.gnu.org/autoconf
synced 2025-01-30 11:01:45 +08:00
* m4sugar.m4 (m4_expand_once): Accept a witness.
This commit is contained in:
parent
bddc739371
commit
6989c24425
@ -1,3 +1,7 @@
|
||||
2001-01-24 Akim Demaille <akim@epita.fr>
|
||||
|
||||
* m4sugar.m4 (m4_expand_once): Accept a witness.
|
||||
|
||||
2001-01-23 Akim Demaille <akim@epita.fr>
|
||||
|
||||
* acgeneral.m4 (AC_EXPAND_ONCE): Remove, use m4_expand_once.
|
||||
|
@ -1279,13 +1279,14 @@ m4_expansion_stack_pop()dnl
|
||||
])
|
||||
|
||||
|
||||
# m4_expand_once(TEXT)
|
||||
# --------------------
|
||||
# If TEXT has never been expanded, expand it *here*.
|
||||
# m4_expand_once(TEXT, [WITNESS = TEXT])
|
||||
# --------------------------------------
|
||||
# If TEXT has never been expanded, expand it *here*. Use WITNESS as
|
||||
# as a memory that TEXT has already been expanded.
|
||||
m4_define([m4_expand_once],
|
||||
[m4_provide_ifelse([$1],
|
||||
[m4_provide_ifelse(m4_ifval([$2], [[$2]], [[$1]]),
|
||||
[],
|
||||
[m4_provide([$1])[]$1])])
|
||||
[m4_provide(m4_ifval([$2], [[$2]], [[$1]]))[]$1])])
|
||||
|
||||
|
||||
# m4_provide(MACRO-NAME)
|
||||
|
11
m4sugar.m4
11
m4sugar.m4
@ -1279,13 +1279,14 @@ m4_expansion_stack_pop()dnl
|
||||
])
|
||||
|
||||
|
||||
# m4_expand_once(TEXT)
|
||||
# --------------------
|
||||
# If TEXT has never been expanded, expand it *here*.
|
||||
# m4_expand_once(TEXT, [WITNESS = TEXT])
|
||||
# --------------------------------------
|
||||
# If TEXT has never been expanded, expand it *here*. Use WITNESS as
|
||||
# as a memory that TEXT has already been expanded.
|
||||
m4_define([m4_expand_once],
|
||||
[m4_provide_ifelse([$1],
|
||||
[m4_provide_ifelse(m4_ifval([$2], [[$2]], [[$1]]),
|
||||
[],
|
||||
[m4_provide([$1])[]$1])])
|
||||
[m4_provide(m4_ifval([$2], [[$2]], [[$1]]))[]$1])])
|
||||
|
||||
|
||||
# m4_provide(MACRO-NAME)
|
||||
|
Loading…
Reference in New Issue
Block a user