expressionof #8557
Unanswered
TonyValenti
asked this question in
Language Ideas
expressionof
#8557
Replies: 1 comment
-
What is a use case for wanting to get a string expression for an arbitrary piece of code? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Today you can use the CallerArgumentExpression to get the string equivalent of an argument that is passed to a method.
There should be an expressionof keyword that does the same thing without the need of a function call.
Expressionof could be achieved today by creating a method that does the job, but this would actually invoke the expression which is undesirable. Also, a method result is not const.
Beta Was this translation helpful? Give feedback.
All reactions