-
-
Notifications
You must be signed in to change notification settings - Fork 122
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Equivalent for Expression Trees #50
Comments
Have you tried decompiling the result of what the C# compiler does? For example here is the result of decompiling a simple |
Yes, but this isn't so much about getting it done at all (just to look at it), but rather about having an automated way (a library!) to do it. |
Could you explain why you want that? Generally, the output of a quoter is useful for a human, because they can then use it to write some other code. But if you want a library, that usually means you want to process the output by a program. But what kind of program prefers e.g. |
A little late to the party, but: @rikimaru0345 I've written a library that allows you to do this, and a Visual Studio debugging visualizer that leverages the library to display this for an expression tree at runtime. @svick Being able to take the source code and convert it the compiler equivalent calls to factory methods is useful, but not always an option; specifically, when I don't have the source code of an expression tree, but only the runtime object. |
Wow @zspitz this is awesome! |
I'll close this issue as this seems to be a great solution: |
zomg |
Hey @KirillOsenkov, first of all RoslynQuoter is really useful, thank you for making it!
However I'm currently looking for a way to do the same for expression trees.
Basically taking c# source code and turning it into
Expression.*
calls.Like an "Expression Tree Quoter" 😄
Google wasn't of any help and since you made this awesome tool, I figured I should just ask you if you're aware of any way that could be done; or maybe a project that already does this. 😄
The text was updated successfully, but these errors were encountered: