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

Unified Diff: base/values.h

Issue 2531113002: Devirtualize DictionaryValue::Remove and DictionaryValue::RemovePath (Closed)
Patch Set: Created 4 years, 1 month 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/values.h
diff --git a/base/values.h b/base/values.h
index 258a9603a614e1a514724434652bd7595b11e7ea..21c3f5fb5cfcd64cc81569057c74f4b11d0cdafa 100644
--- a/base/values.h
+++ b/base/values.h
@@ -327,7 +327,7 @@ class BASE_EXPORT DictionaryValue : public Value {
// |out_value|. If |out_value| is NULL, the removed value will be deleted.
// This method returns true if |path| is a valid path; otherwise it will
// return false and the DictionaryValue object will be unchanged.
- virtual bool Remove(StringPiece path, std::unique_ptr<Value>* out_value);
+ bool Remove(StringPiece path, std::unique_ptr<Value>* out_value);
// Like Remove(), but without special treatment of '.'. This allows e.g. URLs
// to be used as paths.
@@ -336,7 +336,7 @@ class BASE_EXPORT DictionaryValue : public Value {
// Removes a path, clearing out all dictionaries on |path| that remain empty
// after removing the value at |path|.
- virtual bool RemovePath(StringPiece path, std::unique_ptr<Value>* out_value);
+ bool RemovePath(StringPiece path, std::unique_ptr<Value>* out_value);
// Makes a copy of |this| but doesn't include empty dictionaries and lists in
// the copy. This never returns NULL, even if |this| itself is empty.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698