On 2/25/15 7:40 PM, Milo H. Fields wrote:
> Greetings,
>
> I noticed that the ‘bang-hash’ behavior seems to have changed somewhere
> between bash version 4.1.17 and 4.3.33.
>
>
>
> e.g. for the script ‘jnk’ containing:
>
> echo "plain: !#"
> echo " parens: ${!#}"
It changed for Posix mode between bash-4.1 and bash-4.2, specifically in
mid-October 2010. According to Posix, ${!#} and ${!?} are discrete word
expansions (removing prefix pattern and displaying an error if unset,
respectively) involving the $! parameter.
Chet
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU [email protected] http://cnswww.cns.cwru.edu/~chet/