Reply to comment

Your reply

You need to sign up / log in to reply to this comment

Existing comment

I'm not so sure No. 7 is a good example of how to use the nameof operator.

What's the difference between your example $"Argument {nameof(currentUser)} is not provided"

and this? $"Argument currentUser is not provided"

I don't think it's going to give you a compile time error if you make a mistake. Which I think is what you would want to use it for.

Thanks for commenting

Please remember:
Be polite, helpful and keep a positive attitude
Keep it short
Use examples
Review spelling and grammar

Please avoid:
Long texts
Code that is untested
Wall of text