[llvm] [NFC][ADT] Introduce a test harness for StringRefTest (PR #105500)

Sergei Barannikov via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 21 04:51:00 PDT 2024


================
@@ -16,20 +16,7 @@
 #include "gtest/gtest.h"
 using namespace llvm;
 
-namespace llvm {
-
-std::ostream &operator<<(std::ostream &OS, const StringRef &S) {
----------------
s-barannikov wrote:

> So without the << operators, it will call some default printers which won't print the StringRef the right way.

They may or may not work, depending on which instantiation is picked by the linker.

> May be I can add a comment to that effect?

A comment would be great, thanks.


https://github.com/llvm/llvm-project/pull/105500


More information about the llvm-commits mailing list