Don't attempt to forward declare StringPiece.

1) This is discouraged because it prevents callers from benefiting from automatic coersion from string/char* types.
2) A follow-up CL (http://codereview.chromium.org/8659047/) will make StringPiece a template, and thus awkward to forward declare. The very small number of places that were appropriately forward declaring it do not justify writing a 'string_piece_forward.h'.

BUG=87634
R=brettw@chromium.org


Review URL: http://codereview.chromium.org/8820016

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@114124 0039d316-1c4b-4281-b951-d872f2087c98
parent 7f4ad940
......@@ -15,6 +15,7 @@
#include "base/base_export.h"
#include "base/basictypes.h"
#include "base/string16.h"
#include "base/string_piece.h"
#if defined(OS_MACOSX)
#include <CoreFoundation/CoreFoundation.h>
......@@ -27,8 +28,6 @@ class NSString;
namespace base {
class StringPiece;
// Converts between wide and UTF-8 representations of a string. On error, the
// result is system-dependent.
BASE_EXPORT std::string SysWideToUTF8(const std::wstring& wide);
......
......@@ -14,6 +14,7 @@
#include "base/gtest_prod_util.h"
#include "base/memory/scoped_ptr.h"
#include "base/shared_memory.h"
#include "base/string_piece.h"
#include "chrome/browser/extensions/extension_info_map.h"
#include "chrome/common/extensions/extension_messages.h"
#include "chrome/common/extensions/extension_set.h"
......@@ -22,10 +23,6 @@
#include "content/public/browser/notification_observer.h"
#include "content/public/browser/notification_registrar.h"
namespace base {
class StringPiece;
}
namespace content {
class RenderProcessHost;
}
......
// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
// Copyright (c) 2011 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.
......@@ -16,9 +16,10 @@
#include <string>
#include "base/string_piece.h"
namespace base {
class DictionaryValue;
class StringPiece;
}
namespace jstemplate_builder {
......
// Copyright (c) 2009 The Chromium Authors. All rights reserved.
// Copyright (c) 2011 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.
......@@ -6,9 +6,7 @@
#define CHROME_COMMON_NET_NET_RESOURCE_PROVIDER_H_
#pragma once
namespace base {
class StringPiece;
}
#include "base/string_piece.h"
namespace chrome_common_net {
......
......@@ -10,10 +10,6 @@
#include "base/string_piece.h"
#include "v8/include/v8.h"
namespace base {
class StringPiece;
}
// A very simple implementation of v8::ExternalAsciiStringResource that just
// wraps a buffer. The buffer must outlive the v8 runtime instance this resource
// is used in.
......
......@@ -10,13 +10,10 @@
#include <vector>
#include "base/file_path.h"
#include "base/string_piece.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "v8/include/v8.h"
namespace base {
class StringPiece;
}
// A superclass for unit tests that involve running JavaScript. This class
// sets up V8 context and has methods that make it easy to execute scripts in
// this context as well as call functions in the context.
......
......@@ -11,6 +11,7 @@
#include "base/basictypes.h"
#include "base/memory/scoped_ptr.h"
#include "base/string_piece.h"
#include "content/browser/tab_contents/tab_contents_delegate.h"
#include "ui/gfx/native_widget_types.h"
......@@ -18,10 +19,6 @@ class GURL;
class SiteInstance;
class TabContents;
namespace base {
class StringPiece;
}
namespace content {
class BrowserContext;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment