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

Unified Diff: gin/arguments.cc

Issue 74753002: Introduce gin_shell (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix more header nits Created 7 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 | « gin/DEPS ('k') | gin/array_buffer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gin/arguments.cc
diff --git a/gin/arguments.cc b/gin/arguments.cc
index 0a2375cf27aea7180209de8df0f46262c30adc2e..9eedfa3cd9e0250713528e6339edf4d9cd16d53f 100644
--- a/gin/arguments.cc
+++ b/gin/arguments.cc
@@ -4,7 +4,7 @@
#include "gin/arguments.h"
-#include <sstream>
+#include "base/strings/stringprintf.h"
#include "gin/converter.h"
namespace gin {
@@ -29,9 +29,8 @@ void Arguments::ThrowError() {
if (insufficient_arguments_)
return ThrowTypeError("Insufficient number of arguments.");
- std::stringstream stream;
- stream << "Error processing argument " << next_ - 1 << ".";
- ThrowTypeError(stream.str());
+ ThrowTypeError(base::StringPrintf(
+ "Error processing argument %d.", next_ - 1));
}
void Arguments::ThrowTypeError(const std::string& message) {
« no previous file with comments | « gin/DEPS ('k') | gin/array_buffer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698