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

Unified Diff: lib/Values_h.template

Issue 2490733002: [inspector_protocol] Allow custom json parser. (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 | « lib/Parser_h.template ('k') | templates/TypeBuilder_cpp.template » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/Values_h.template
diff --git a/lib/Values_h.template b/lib/Values_h.template
index 8f75ef2220e26ed678e1d3bf273d43d6a86d3217..8e0d555d213998bd9642d96158b925b0062320a0 100644
--- a/lib/Values_h.template
+++ b/lib/Values_h.template
@@ -24,7 +24,7 @@ public:
static std::unique_ptr<Value> null()
{
- return wrapUnique(new Value());
+ return std::unique_ptr<Value>(new Value());
}
enum ValueType {
@@ -67,17 +67,17 @@ class {{config.lib.export_macro}} FundamentalValue : public Value {
public:
static std::unique_ptr<FundamentalValue> create(bool value)
{
- return wrapUnique(new FundamentalValue(value));
+ return std::unique_ptr<FundamentalValue>(new FundamentalValue(value));
}
static std::unique_ptr<FundamentalValue> create(int value)
{
- return wrapUnique(new FundamentalValue(value));
+ return std::unique_ptr<FundamentalValue>(new FundamentalValue(value));
}
static std::unique_ptr<FundamentalValue> create(double value)
{
- return wrapUnique(new FundamentalValue(value));
+ return std::unique_ptr<FundamentalValue>(new FundamentalValue(value));
}
bool asBoolean(bool* output) const override;
@@ -102,12 +102,12 @@ class {{config.lib.export_macro}} StringValue : public Value {
public:
static std::unique_ptr<StringValue> create(const String& value)
{
- return wrapUnique(new StringValue(value));
+ return std::unique_ptr<StringValue>(new StringValue(value));
}
static std::unique_ptr<StringValue> create(const char* value)
{
- return wrapUnique(new StringValue(value));
+ return std::unique_ptr<StringValue>(new StringValue(value));
}
bool asString(String* output) const override;
@@ -125,7 +125,7 @@ class {{config.lib.export_macro}} SerializedValue : public Value {
public:
static std::unique_ptr<SerializedValue> create(const String& value)
{
- return wrapUnique(new SerializedValue(value));
+ return std::unique_ptr<SerializedValue>(new SerializedValue(value));
}
bool asSerialized(String* output) const override;
@@ -143,7 +143,7 @@ public:
using Entry = std::pair<String, Value*>;
static std::unique_ptr<DictionaryValue> create()
{
- return wrapUnique(new DictionaryValue());
+ return std::unique_ptr<DictionaryValue>(new DictionaryValue());
}
static DictionaryValue* cast(Value* value)
@@ -155,7 +155,7 @@ public:
static std::unique_ptr<DictionaryValue> cast(std::unique_ptr<Value> value)
{
- return wrapUnique(DictionaryValue::cast(value.release()));
+ return std::unique_ptr<DictionaryValue>(DictionaryValue::cast(value.release()));
}
void writeJSON(StringBuilder* output) const override;
@@ -209,7 +209,7 @@ class {{config.lib.export_macro}} ListValue : public Value {
public:
static std::unique_ptr<ListValue> create()
{
- return wrapUnique(new ListValue());
+ return std::unique_ptr<ListValue>(new ListValue());
}
static ListValue* cast(Value* value)
@@ -221,7 +221,7 @@ public:
static std::unique_ptr<ListValue> cast(std::unique_ptr<Value> value)
{
- return wrapUnique(ListValue::cast(value.release()));
+ return std::unique_ptr<ListValue>(ListValue::cast(value.release()));
}
~ListValue() override;
« no previous file with comments | « lib/Parser_h.template ('k') | templates/TypeBuilder_cpp.template » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698