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

Unified Diff: base/string_piece.h

Issue 9159005: Move operator<< for StringPiece into string_piece.{h,cc} (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix license Created 8 years, 11 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 | « base/logging.cc ('k') | base/string_piece.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/string_piece.h
diff --git a/base/string_piece.h b/base/string_piece.h
index e68302e466e2dc4a70f68fc5588d7e78ffae2ce5..7bce4ff8ca78e664c10b5b6bfd748873dbc92b01 100644
--- a/base/string_piece.h
+++ b/base/string_piece.h
@@ -1,4 +1,4 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Copied from strings/stringpiece.h with modifications
@@ -24,6 +24,7 @@
#define BASE_STRING_PIECE_H_
#pragma once
+#include <iosfwd>
#include <string>
#include "base/base_export.h"
@@ -399,6 +400,9 @@ inline bool operator>=(const StringPiece16& x, const StringPiece16& y) {
return !(x < y);
}
+BASE_EXPORT std::ostream& operator<<(std::ostream& o,
+ const StringPiece& piece);
+
} // namespace base
// We provide appropriate hash functions so StringPiece and StringPiece16 can
« no previous file with comments | « base/logging.cc ('k') | base/string_piece.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698