[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: more efficient AS_EXIT
From: |
Eric Blake |
Subject: |
Re: more efficient AS_EXIT |
Date: |
Sat, 22 Nov 2008 06:19:49 -0700 |
User-agent: |
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.18) Gecko/20081105 Thunderbird/2.0.0.18 Mnenhy/0.7.5.666 |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
According to Ralf Wildenhues on 11/22/2008 6:13 AM:
>> exit_missing_arg='
>> - AS_ECHO(["$as_me: option \`$[1]'\'' requires an argument"]) >&2
>> - AS_ECHO(["$help"]) >&2
>> - AS_EXIT([1])
>> -' # restore font-lock: "
>> + m4_bpatsubst([AS_ERROR([option `$[1]' requires an argument$as_nl$help])],
>> + ['], ['\\''])'
>
> Why is that m4_bpatsubst needed here ...
Because it is in a single-quoted context (exit_missing_arg='text'), which
will later be used as
eval "$exit_missing_arg"
I suppose it could also be written:
exit_missing_arg="
AS_ESCAPE([AS_ERROR([option `$[1]' requires an argument$as_nl$help])])"
so that the bpatsubst is done under the hood by AS_ESCAPE.
>> + AS_ERROR([invalid option `$[1]'$as_nl$help]) ;; #`
>
> ... but not here?
Because that is used literally (AS_ERROR supplies the double-quote context
around its arguments).
- --
Don't work too hard, make some time for fun as well!
Eric Blake address@hidden
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iEYEARECAAYFAkkoBvUACgkQ84KuGfSFAYBFiwCeJW5fJ3wgNQGaWIokFyGoi1Sq
pvMAniGMJNOltBE5v4RTgETEk09Kxbf2
=UUHs
-----END PGP SIGNATURE-----
- Re: more efficient AS_EXIT, (continued)
- Re: more efficient AS_EXIT, Eric Blake, 2008/11/18
- Re: more efficient AS_EXIT, Paolo Bonzini, 2008/11/19
- Re: more efficient AS_EXIT, Eric Blake, 2008/11/19
- Re: more efficient AS_EXIT, Paolo Bonzini, 2008/11/20
- Re: more efficient AS_EXIT, Eric Blake, 2008/11/20
- Re: more efficient AS_EXIT, Paolo Bonzini, 2008/11/21
- Re: more efficient AS_EXIT, Eric Blake, 2008/11/21
- Re: more efficient AS_EXIT, Ralf Wildenhues, 2008/11/22
- Re: more efficient AS_EXIT, Ralf Wildenhues, 2008/11/22
- Re: more efficient AS_EXIT,
Eric Blake <=