Scan/parse does not believe in some forms of scientific notation
|
|
Bugzilla Link |
1140 |
Created on |
Oct 14, 2014 21:33 |
Resolution |
FIXED |
Resolved on |
Nov 05, 2015 19:53 |
Version |
svn |
OS |
Linux |
Architecture |
PC |
Extended Description
Specifically, this example fails on the line assigning to z:
cat scientificnotationbug.sac
int main()
{
x = 1.2e+3;
StdIO::print();
y = 1.2e-3;
StdIO::print(y);
z = 1.2e3; // This should work.
StdIO::print(z);
return(0);
}
sac@rattler:~/sac/testsuite/optimizations/awlf$ sac2c scientificnotationbug.sac
./scientificnotationbug.sac 9:11 error:
=> + or - expected after exponent
./scientificnotationbug.sac 9:7 error:
=> token 1.2e cannot start an expression.
abort: Failed to construct a syntax tree for `scientificnotationbug.sac'
compilation failed while Loading SAC program, 2 error(s).
sac2c -V
sac2c v1.00-beta (Haggis And Apple)
product rev 18509 linux-gnu_x86_64
(Tue Oct 14 15:48:09 EDT 2014 by sac)
This did work, once upon a time, I believe.