There is an unsaved comment in progress. You will lose your changes if you continue. Are you sure you want to reopen the work item?
Issue at 'pi' and 'e' constants
I was working in C# using the Mathos Parser (v22.214.171.124), and I noticed that when I used the command
the value returned by the parser was 314159265358979 (pi * 100000000000000). The comma/dot just disappeared.
I've already found a solution by myself, I'll write it here so it can be fixed for everyone:
At line 407 of MathParser.cs, the command
_tokens[i] = LocalVariables[_tokens[i]].ToString();
has been returning a value with comma, and the program just work with dot. That's the issue. The solution is to change this command to this:
_tokens[i] = LocalVariables[_tokens[i]].ToString().Replace(',', '.');
I did this change and the problem is solved.
I hope it can help someone!
P.S.: Good work Artem Los, your code helped me a lot!