Bug#732509: mksh: missing octal support in arithmetic expressions

2014-01-07 Thread Vincent Lefevre
On 2013-12-18 16:48:46 +, Thorsten Glaser wrote: > Vincent Lefevre dixit: > >mksh intends to behave like ksh93. > > No. mksh only takes AT&T ksh93 behaviour as primary rule of > thumb. In fact, you will find that ksh93 behaves unlike all > other modern shells in many ways, such as scoping. > >

Bug#732509: mksh: missing octal support in arithmetic expressions

2014-01-07 Thread Thorsten Glaser
Vincent Lefevre dixit: >Well, that's very confusing, because both ksh93 and mksh are >ksh alternatives. This can break scripts with "#!/bin/ksh". ksh93 can break scripts with "#!/bin/ksh" because interpreting leading-digit-zero numbers as octal is a *very* recent change, and is *known* to break e

Bug#732509: mksh: missing octal support in arithmetic expressions

2014-01-03 Thread Vincent Lefevre
On 2013-12-18 18:08:59 +, Thorsten Glaser wrote: > Vincent Lefevre dixit: > >Well, that's very confusing, because both ksh93 and mksh are > >ksh alternatives. This can break scripts with "#!/bin/ksh". > > ksh93 can break scripts with "#!/bin/ksh" because interpreting > leading-digit-zero numbe

Bug#732509: mksh: missing octal support in arithmetic expressions

2013-12-18 Thread Thorsten Glaser
Vincent Lefevre dixit: >Well, that's very confusing, because both ksh93 and mksh are >ksh alternatives. This can break scripts with "#!/bin/ksh". ksh93 can break scripts with "#!/bin/ksh" because interpreting leading-digit-zero numbers as octal is a *very* recent change, and is *known* to break e

Bug#732509: mksh: missing octal support in arithmetic expressions

2013-12-18 Thread Vincent Lefevre
On 2013-12-18 16:48:46 +, Thorsten Glaser wrote: > Vincent Lefevre dixit: > >mksh intends to behave like ksh93. > > No. mksh only takes AT&T ksh93 behaviour as primary rule of > thumb. In fact, you will find that ksh93 behaves unlike all > other modern shells in many ways, such as scoping. >

Bug#732509: mksh: missing octal support in arithmetic expressions

2013-12-18 Thread Vincent Lefevre
And be careful not to break test/[. $ mksh -c '[ 10 -eq 010 ] && echo OK' OK is correct. On this subject, see Geoff Clare's message in the Austin Group mailing-list: http://permalink.gmane.org/gmane.comp.standards.posix.austin.general/8862 -- Vincent Lefèvre - Web:

Bug#732509: mksh: missing octal support in arithmetic expressions

2013-12-18 Thread Vincent Lefevre
Package: mksh Version: 46-2 Severity: normal Unlike ksh (and sh), mksh doesn't support octal in arithmetic expressions: xvii% sh -c 'echo $((010))' 8 xvii% ksh93 -c 'echo $((010))' 8 xvii% mksh -c 'echo $((010))' 10 I hate this feature because of the ambiguity with decimal, but mksh intends to b