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

Unified Diff: base/file_path.h

Issue 165330: Disable RTTI and C++ exceptions (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 4 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 | « no previous file | base/hash_tables.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/file_path.h
===================================================================
--- base/file_path.h (revision 23061)
+++ base/file_path.h (working copy)
@@ -66,6 +66,7 @@
#define BASE_FILE_PATH_H_
#include <string>
+#include <vector>
#include "base/basictypes.h"
#include "base/compiler_specific.h"
@@ -256,14 +257,15 @@
#define FILE_PATH_LITERAL(x) L ## x
#endif // OS_WIN
-// Implement hash function so that we can use FilePaths in hashsets and maps.
+// Provide a hash function so that hash_sets and maps can contain FilePath
+// objects.
#if defined(COMPILER_GCC)
namespace __gnu_cxx {
template<>
struct hash<FilePath> {
- size_t operator()(const FilePath& f) const {
- return std::tr1::hash<FilePath::StringType>()(f.value());
+ std::size_t operator()(const FilePath& f) const {
+ return hash<FilePath::StringType>()(f.value());
}
};
« no previous file with comments | « no previous file | base/hash_tables.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698