Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(403)

Unified Diff: Source/wtf/text/WTFString.h

Issue 1257203002: Fix ODR violation that can break WTF::String pretty printing in tests. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Really fix Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/wtf/text/StringBuilderTest.cpp ('k') | Source/wtf/wtf.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/wtf/text/WTFString.h
diff --git a/Source/wtf/text/WTFString.h b/Source/wtf/text/WTFString.h
index d6c82501417f8605de3c1f086aac5c888192be9b..f06ed79dbc305cce03387bb3d2eddf138aa33bc5 100644
--- a/Source/wtf/text/WTFString.h
+++ b/Source/wtf/text/WTFString.h
@@ -27,10 +27,12 @@
#include "wtf/HashTableDeletedValueType.h"
#include "wtf/WTFExport.h"
+#include "wtf/testing/WTFUnitTestHelpersExport.h"
#include "wtf/text/ASCIIFastPath.h"
#include "wtf/text/StringImpl.h"
#include "wtf/text/StringView.h"
#include <algorithm>
+#include <iosfwd>
#ifdef __OBJC__
#include <objc/objc.h>
@@ -633,6 +635,9 @@ WTF_EXPORT const String& emptyString();
WTF_EXPORT const String& emptyString16Bit();
WTF_EXPORT extern const String& xmlnsWithColon;
+// Pretty printer for gtest. Declared here to avoid ODR violations.
+WTF_UNITTEST_HELPERS_EXPORT std::ostream& operator<<(std::ostream&, const String&);
Julien - ping for review 2015/07/28 17:35:32 It seems to me that we would benefit from a printe
+
} // namespace WTF
WTF_ALLOW_MOVE_AND_INIT_WITH_MEM_FUNCTIONS(String);
« no previous file with comments | « Source/wtf/text/StringBuilderTest.cpp ('k') | Source/wtf/wtf.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698