Tina Harriott
2013-10-22 22:53:59 UTC
ast-ksh 2013-10-10 introduced suffices for floating point constants:
13-10-08 The shell arithmetic now recognized suffices f,F, l, and L for
floating point constants.
However, they do not work:
./arch/linux.i386-64/bin/ksh -c 'print $((1.1f))'
./arch/linux.i386-64/bin/ksh: 1.1f: arithmetic syntax error
./arch/linux.i386-64/bin/ksh -c 'print $((x=1.1f))'
./arch/linux.i386-64/bin/ksh: x=1.1f: arithmetic syntax error
./arch/linux.i386-64/bin/ksh -c 'float x ; print $((x=1.1f))'
./arch/linux.i386-64/bin/ksh: x=1.1f: arithmetic syntax error
./arch/linux.i386-64/bin/ksh -c 'float x ; print $((x=1.1F))'
./arch/linux.i386-64/bin/ksh: x=1.1F: arithmetic syntax error
./arch/linux.i386-64/bin/ksh -c 'float x ; print $((x=1.1l))'
./arch/linux.i386-64/bin/ksh: x=1.1l: arithmetic syntax error
./arch/linux.i386-64/bin/ksh -c 'float x ; ((x=1.1l))'
./arch/linux.i386-64/bin/ksh: x=1.1l: arithmetic syntax error
If possible, can ksh please get the same kind of suffices for integer
constants, to have parity?
Tina
13-10-08 The shell arithmetic now recognized suffices f,F, l, and L for
floating point constants.
However, they do not work:
./arch/linux.i386-64/bin/ksh -c 'print $((1.1f))'
./arch/linux.i386-64/bin/ksh: 1.1f: arithmetic syntax error
./arch/linux.i386-64/bin/ksh -c 'print $((x=1.1f))'
./arch/linux.i386-64/bin/ksh: x=1.1f: arithmetic syntax error
./arch/linux.i386-64/bin/ksh -c 'float x ; print $((x=1.1f))'
./arch/linux.i386-64/bin/ksh: x=1.1f: arithmetic syntax error
./arch/linux.i386-64/bin/ksh -c 'float x ; print $((x=1.1F))'
./arch/linux.i386-64/bin/ksh: x=1.1F: arithmetic syntax error
./arch/linux.i386-64/bin/ksh -c 'float x ; print $((x=1.1l))'
./arch/linux.i386-64/bin/ksh: x=1.1l: arithmetic syntax error
./arch/linux.i386-64/bin/ksh -c 'float x ; ((x=1.1l))'
./arch/linux.i386-64/bin/ksh: x=1.1l: arithmetic syntax error
If possible, can ksh please get the same kind of suffices for integer
constants, to have parity?
Tina
--
Tina Harriott - Women in Mathematics
Contact: tina.harriott.math at gmail.com
Tina Harriott - Women in Mathematics
Contact: tina.harriott.math at gmail.com