Repository navigation
|
Hi, is it possible to use cond or choose to check whether two values are the same? It seems that Fiddle: https://dotnetfiddle.net/08nHRw |
Replies: 1 comment 2 replies
|
Hi @mhspelt A fix could format with an additional parameter with equality: Evaluating A PR for allowing |
Hi @mhspelt
Yes, you are right, the comparison currently requires a literal. A placeholder does not work.
A fix could format with an additional parameter with equality:
Fiddle: https://dotnetfiddle.net/OjHoRj
Did you find a better solution?
Evaluating
Placeholders would be a nice improvement, though. TheFormatfrom theParseralready returns allPlaceholders. TheConditionalFormatterhowever assumes that childFormats in the parameters are not nested. It should rather make sure and throw for nested parameters.A PR for allowing
Placeholders would be great ;-)