mclow.lists created this revision. mclow.lists added a reviewer: rsmith. mclow.lists added a subscriber: cfe-commits.
Last week, WG21 approved a paper (http://wg21.link/P0403) for allowing literal suffixes for `string_view`. This means that should be able to write: constexpr std::string_view sv = "1234"sv; However, clang has a list of all the allowable suffixes. Update the list to include `"sv"` https://reviews.llvm.org/D26667 Files: lib/Lex/LiteralSupport.cpp Index: lib/Lex/LiteralSupport.cpp =================================================================== --- lib/Lex/LiteralSupport.cpp +++ lib/Lex/LiteralSupport.cpp @@ -765,6 +765,7 @@ .Cases("h", "min", "s", true) .Cases("ms", "us", "ns", true) .Cases("il", "i", "if", true) + .Case("sv", true) .Default(false); }
Index: lib/Lex/LiteralSupport.cpp =================================================================== --- lib/Lex/LiteralSupport.cpp +++ lib/Lex/LiteralSupport.cpp @@ -765,6 +765,7 @@ .Cases("h", "min", "s", true) .Cases("ms", "us", "ns", true) .Cases("il", "i", "if", true) + .Case("sv", true) .Default(false); }
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits