vtkFunctionParser gives wrong results for numeric literals
This issue was created automatically from an original Mantis Issue. Further discussion may take place here.
The vtkFunctionParser wrongly parses numeric literals with exponent notation. For example, "3.0e+01" is parsed as 31.0 = 3.0e01 + 01. I have confirmed the phenomena on VTK version 6.2.0.
----- sample code in python ----- import vtk f = vtk.vtkFunctionParser() f.SetFunction("3.0e+01") print f.GetScalarResult()
=> 31.0
I noticed that only the '(\d)e-(\d)' case is treated specially in vtkFunctionParser.cxx:l.1542, but I have no graceful idea to fix it.