Hacker News new | ask | show | jobs
by ygra 2239 days ago
There's plenty of contexts where the extra indentation doesn't matter, though. And C#'s verbatim strings, at least when it comes to multiple lines, have the benefit of being extremely predictable in what ends up in the string (everything, including whitespace). They also have other uses that Java doesn't even address, like not interpreting escape sequences inside the string.

I'm not sure you can really compare them. They're two different features with fairly different uses, it's just that one or two of those uses somewhat overlap.

1 comments

They're comparable in the sense that I'm guessing C# is unlikely to get yet another string declaration syntax, so we're stuck with what we've got. Regarding predictability I definitely agree, but good syntax highlighting would help with that.