
23 Apr
2017
23 Apr
'17
12:32 a.m.
On 23 April 2017 at 03:59, Andrew McGlashan via luv-main <luv-main@luv.asn.au> wrote:
The return code from ((i++)) operation is different when i has an initial value of 0.
Well, that is by consistent design, so I wouldn't consider that a bug, myself. Bash provides pre- and post- increment and decrement operators, and you seem to have chosen the wrong one. $ i=0; ((i++)); echo $? 1 $ i=0; ((++i)); echo $? 0 Search 'man bash' for the string "pre-increment".