From: Mark Wooding Date: Sat, 4 May 2024 14:42:15 +0000 (+0100) Subject: defs.m4: Document the behaviour of omitting `KV' apodosis/haeresis args. X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~mdw/git/exim-config/commitdiff_plain/3a58bd3cb2cc0ea1054547819356aceba4d8ab11 defs.m4: Document the behaviour of omitting `KV' apodosis/haeresis args. --- diff --git a/defs.m4 b/defs.m4 index 8be119d..8beb3b1 100644 --- a/defs.m4 +++ b/defs.m4 @@ -169,16 +169,17 @@ m4_define(<:LOOKUP_DOMAIN:>, _LOOKUP_ARGS(<:$2:>, <:$3:>)}} \ $3:>) -## KV(key, result) +## KV(key, [result]) ## ## Extract the value of the named KEY in the ${extract ...}-style string in ## the current $value (where it may have been left by `LOOKUP-DOMAIN'). The ## RESULT is a pair {IF-FOUND}{IF-NOT-FOUND}; the former may use $value to ## refer to the value; the latter may be `fail' (not in braces) to force -## expansion failure. +## expansion failure. The default is to expand to the extracted value or +## nothing. m4_define(<:KV:>, <:${extract {$1}{$value}$2}:>) -## DOMKV(key, result) +## DOMKV(key, [result]) ## ## Extract the value of the named KEY in the ${extract ...}-style string in ## $domain_data; see `KV'.