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

Unified Diff: third_party/protobuf/src/google/protobuf/util/internal/type_info.cc

Issue 2495533002: third_party/protobuf: Update to HEAD (83d681ee2c) (Closed)
Patch Set: Make chrome settings proto generated file a component Created 4 years 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
Index: third_party/protobuf/src/google/protobuf/util/internal/type_info.cc
diff --git a/third_party/protobuf/src/google/protobuf/util/internal/type_info.cc b/third_party/protobuf/src/google/protobuf/util/internal/type_info.cc
index 00a8ee7a2affa2f2ff5046958f0f35f98a9c3b6a..17d58475554a6ca130d13a9a10a8d5f36c41e30c 100644
--- a/third_party/protobuf/src/google/protobuf/util/internal/type_info.cc
+++ b/third_party/protobuf/src/google/protobuf/util/internal/type_info.cc
@@ -60,7 +60,8 @@ class TypeInfoForTypeResolver : public TypeInfo {
virtual util::StatusOr<const google::protobuf::Type*> ResolveTypeUrl(
StringPiece type_url) const {
- map<StringPiece, StatusOrType>::iterator it = cached_types_.find(type_url);
+ std::map<StringPiece, StatusOrType>::iterator it =
+ cached_types_.find(type_url);
if (it != cached_types_.end()) {
return it->second;
}
@@ -85,7 +86,8 @@ class TypeInfoForTypeResolver : public TypeInfo {
virtual const google::protobuf::Enum* GetEnumByTypeUrl(
StringPiece type_url) const {
- map<StringPiece, StatusOrEnum>::iterator it = cached_enums_.find(type_url);
+ std::map<StringPiece, StatusOrEnum>::iterator it =
+ cached_enums_.find(type_url);
if (it != cached_enums_.end()) {
return it->second.ok() ? it->second.ValueOrDie() : NULL;
}
@@ -123,8 +125,8 @@ class TypeInfoForTypeResolver : public TypeInfo {
typedef util::StatusOr<const google::protobuf::Enum*> StatusOrEnum;
template <typename T>
- static void DeleteCachedTypes(map<StringPiece, T>* cached_types) {
- for (typename map<StringPiece, T>::iterator it = cached_types->begin();
+ static void DeleteCachedTypes(std::map<StringPiece, T>* cached_types) {
+ for (typename std::map<StringPiece, T>::iterator it = cached_types->begin();
it != cached_types->end(); ++it) {
if (it->second.ok()) {
delete it->second.ValueOrDie();
@@ -151,13 +153,13 @@ class TypeInfoForTypeResolver : public TypeInfo {
// Stores string values that will be referenced by StringPieces in
// cached_types_, cached_enums_ and camel_case_name_table_.
- mutable set<string> string_storage_;
+ mutable std::set<string> string_storage_;
- mutable map<StringPiece, StatusOrType> cached_types_;
- mutable map<StringPiece, StatusOrEnum> cached_enums_;
+ mutable std::map<StringPiece, StatusOrType> cached_types_;
+ mutable std::map<StringPiece, StatusOrEnum> cached_enums_;
- mutable set<const google::protobuf::Type*> indexed_types_;
- mutable map<StringPiece, StringPiece> camel_case_name_table_;
+ mutable std::set<const google::protobuf::Type*> indexed_types_;
+ mutable std::map<StringPiece, StringPiece> camel_case_name_table_;
};
} // namespace

Powered by Google App Engine
This is Rietveld 408576698