2 ms·
It's a problem all languages with <..> need to solve one way or the other; see e.g. https://blog.dyvil.org/syntax/2016/04/19/angle-bracket-generics.html https:/
by arp242 5y ago
It's a problem all languages with <..> need to solve one way or the other; see e.g. https://blog.dyvil.org/syntax/2016/04/19/angle-bracket-generics.html https://blog.dyvil.org/syntax/2016/04/19/angle-bracket-gener...
So for C# it's resolved "by examining the token after the closing >: If it is one of (, ), ], :, ;, ,, ., ?, == or !=, the expression is parsed as a generic method call."
I assume this works reasonably well; however, it's not hard to see how this might be a problem in some cases where the parser gets it wrong.
- blondin 5y agothanks for explaining :)