nreco / lambdaparser

Runtime parser for string expressions (formulas, method calls). Builds dynamic LINQ expression tree and compiles it to lambda delegate.
http://www.nrecosite.com/
MIT License
309 stars 55 forks source link

Non-convertible types support #40

Open maagy opened 2 years ago

maagy commented 2 years ago

Would it be possible to support operations with types that support these operations but are not IConvertible?

Example:

varContext["complexZero"] = new System.Numerics.Complex();
varContext["complexOne"] = new System.Numerics.Complex(1d, 1d);

lambdaParser.Eval("complexOne * complexZero", varContext)