[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: doesn't bash do variable subst. or quote removal on function stateme

From: Chet Ramey
Subject: Re: doesn't bash do variable subst. or quote removal on function statement
Date: Wed, 13 Jan 2016 14:25:46 -0500
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:38.0) Gecko/20100101 Thunderbird/38.5.1

On 1/13/16 12:20 PM, Linda Walsh wrote:

> It doesn't seem very consistent to choose (()) over [] -- why come up with
> a special longer operator for arith eval, when [] was already used for
> arith evaluation in array indexing?


"In early proposals, a form $[expression] was used. It was functionally
equivalent to the "$(())" of the current text, but objections were lodged
that the 1988 KornShell had already implemented "$(())" and there was no
compelling reason to invent yet another syntax. Furthermore, the "$[]"
syntax had a minor incompatibility involving the patterns in case

Remember that Posix doesn't standardize arrays.

``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU    address@hidden    http://cnswww.cns.cwru.edu/~chet/

reply via email to

[Prev in Thread] Current Thread [Next in Thread]