[PATCH] D27686: Add llvm::StringLiteral

Malcolm Parsons via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 12 23:53:57 PST 2016


malcolm.parsons requested changes to this revision.
malcolm.parsons added inline comments.
This revision now requires changes to proceed.


================
Comment at: unittests/ADT/StringRefTest.cpp:1007
+  constexpr StringLiteral Strings[] = {"Foo", "Bar"};
+  EXPECT_STREQ("Foo", Strings[0].data());
+  EXPECT_STREQ("Bar", Strings[1].data());
----------------
There is no test for the length of the StrlingLiteral.
Maybe `EXPECT_EQ(StringRef("Foo"), Strings[0]);`


https://reviews.llvm.org/D27686





More information about the llvm-commits mailing list