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

Unified Diff: base/json/json_writer.h

Issue 2695873002: Prevent some string copies when sending Values to WebUI. (Closed)
Patch Set: Removed another copy Created 3 years, 10 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 | content/browser/webui/web_ui_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/json/json_writer.h
diff --git a/base/json/json_writer.h b/base/json/json_writer.h
index ef433414090aa5aea7f889193c86ead13bb1c4fd..57cb8c16a29031d924be9f08e8a918ec826dba88 100644
--- a/base/json/json_writer.h
+++ b/base/json/json_writer.h
@@ -37,6 +37,8 @@ class BASE_EXPORT JSONWriter {
};
// Given a root node, generates a JSON string and puts it into |json|.
+ // The output string is overwritten and not appended.
+ //
// TODO(tc): Should we generate json if it would be invalid json (e.g.,
// |node| is not a DictionaryValue/ListValue or if there are inf/-inf float
// values)? Return true on success and false on failure.
« no previous file with comments | « no previous file | content/browser/webui/web_ui_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698