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
307 stars 55 forks source link

LambdaParser.Parse #24

Closed Mike-E-angelo closed 4 years ago

Mike-E-angelo commented 4 years ago

We're exploring a possible use case here: https://github.com/ExtendedXmlSerializer/home/issues/382

And the thought arose to check out your parser, which has a Parse method. :)

However, I am having some trouble using it and feel I may be using it incorrectly. Unfortunately I do not see any tests around this method, so asking here.

Is it possible to use this method to parse the following into a expression (of Func<int>)?

"() => 123"

Thank you for any guidance you can provide. 👍

Mike-E-angelo commented 4 years ago

Looks like we got our answer directly on our repo. Thank you @VitaliyMF!