Replies: 3 comments 10 replies
-
I don't understand why cref and nameof uses two different syntaxes. If the shorter nameof form is not ambiguous in nameof, why use the longer form in cref. Why introduce two distinct concepts here? |
Beta Was this translation helpful? Give feedback.
-
Nameof references a group of symbols with a particular name. Crefs have to reference individual symbols, which may have no name. Nameof also literally has no syntax specific to it. It's syntactically an invocation with an expression arg. That's not the case with cref.
The concepts are already distinct, and have been since the introduction of the features. |
Beta Was this translation helpful? Give feedback.
-
I'm not entirely clear on what the difficult part is about |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
https://github.com/dotnet/csharplang/blob/main/meetings/2025/LDM-2025-06-11.md
Agenda
true
/false
nameof
Beta Was this translation helpful? Give feedback.
All reactions