Dear Artem Los and everyone else involved in this project,
I think that this library is an ideal candidate for turning into a Portable Class Library (PCL). I just tested, and right now you only have to change one line in the
file and remove the anyway redundant [assembly:ComVisible(false)]
lines in AssemblyInfo.cs
to be able to target practically all PCL platforms, i.e.
- .NET Framework 4 and higher
- Windows 8 (f.k.a Store or Metro) and higher
- Windows Phone Silverlight 8 and 8.1
- Windows Phone 8.1
- Silverlight 5
The only change you need to do in the MathParser
source code is to replace the call to
(used in line 125 in the current changeset), since this method is not available in PCL. I believe the following line should provide a sufficient replacement:
LocalFunctions.Add("truncate", x => (decimal)(x < 0.0m ? -Math.Floor(-(double)x) : Math.Floor((double)x)));
Thanks in advance!
Anders @ Cureos