Re:ASCII and Unicode quotation marks
by stormbrew on Wednesday September 13, 2017 @09:41PM
(#15244376)
Ruby lets you use arbitrary tokens for string literals with %s{} (where the braces can be a bunch of things). I wish more languages would adopt this tbh.
[ Parent
| on HN ]
Re:ASCII and Unicode quotation marks
by ziotom78 on Thursday September 14, 2017 @03:14AM
(#15245587)
C++11 has this feature too [1], e.g.:
const char * str = R"*^*(This is string containing an embedded "quoted" string)*^*";
[1] http://en.cppreference.com/w/cpp/language/string_literalApache Groovy also had that in its early 1.0 betas but they were removed before their official 1.0 release party.