Closed
Description
C#10 has a nice addition of CallerArgumentExpressionAttribute, which we could use to print actual
argument expression in error messages.
I can see two problems though:
- We need to add optional
string
parameter to methods. But we already have overloads withmessage
string parameter. - We have methods with
params
parameter. And we can't combineparams
and optional parameters in the same method.
Is there any way we could make use of this attribute?