| Index: tools/json_schema_compiler/cc_generator.py
|
| diff --git a/tools/json_schema_compiler/cc_generator.py b/tools/json_schema_compiler/cc_generator.py
|
| index dcd28ce58b5f7b379969df57b6fa5ec03601eb34..c3259561beb66dfa69529824b46fcea741891d2a 100644
|
| --- a/tools/json_schema_compiler/cc_generator.py
|
| +++ b/tools/json_schema_compiler/cc_generator.py
|
| @@ -650,7 +650,7 @@ class _Generator(object):
|
| if underlying_type.property_type == PropertyType.STRING:
|
| return 'base::MakeUnique<base::StringValue>(%s)' % var
|
| else:
|
| - return 'base::MakeUnique<base::FundamentalValue>(%s)' % var
|
| + return 'base::MakeUnique<base::Value>(%s)' % var
|
| else:
|
| raise NotImplementedError('Conversion of %s to base::Value not '
|
| 'implemented' % repr(type_.type_))
|
| @@ -766,7 +766,7 @@ class _Generator(object):
|
| if underlying_type.property_type.is_fundamental:
|
| if is_ptr:
|
| (c.Append('%(cpp_type)s temp;')
|
| - .Sblock('if (!%s) {' % cpp_util.GetAsFundamentalValue(
|
| + .Sblock('if (!%s) {' % cpp_util.GetAsValue(
|
| self._type_helper.FollowRef(type_), src_var, '&temp'))
|
| .Concat(self._GenerateError(
|
| '"\'%%(key)s\': expected ' + '%s, got " + %s' % (
|
| @@ -781,7 +781,7 @@ class _Generator(object):
|
| .Append(' %(dst_var)s.reset(new %(cpp_type)s(temp));')
|
| )
|
| else:
|
| - (c.Sblock('if (!%s) {' % cpp_util.GetAsFundamentalValue(
|
| + (c.Sblock('if (!%s) {' % cpp_util.GetAsValue(
|
| self._type_helper.FollowRef(type_),
|
| src_var,
|
| '&%s' % dst_var))
|
|
|