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

Unified Diff: tools/json_schema_compiler/cpp_type_generator.py

Issue 12283025: JSON Compiler should convert the namespace value in lowerCamelCase to unix_name for the referenced … (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: Created 7 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
Index: tools/json_schema_compiler/cpp_type_generator.py
===================================================================
--- tools/json_schema_compiler/cpp_type_generator.py (revision 182503)
+++ tools/json_schema_compiler/cpp_type_generator.py (working copy)
@@ -97,7 +97,7 @@
if self._default_namespace is ref_type.namespace:
cpp_type = ref_type.name
else:
- cpp_type = '%s::%s' % (ref_type.namespace.name, ref_type.name)
+ cpp_type = '%s::%s' % (ref_type.namespace.unix_name, ref_type.name)
elif type_.property_type == PropertyType.BOOLEAN:
cpp_type = 'bool'
elif type_.property_type == PropertyType.INTEGER:
@@ -151,7 +151,7 @@
c = Code()
for namespace, dependencies in self._NamespaceTypeDependencies().items():
- c.Append('namespace %s {' % namespace.name)
+ c.Append('namespace %s {' % namespace.unix_name)
for dependency in dependencies:
# No point forward-declaring hard dependencies.
if dependency.hard:
« tools/json_schema_compiler/compiler.py ('K') | « tools/json_schema_compiler/compiler.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698