Index: tools/json_schema_compiler/idl_schema.py |
diff --git a/tools/json_schema_compiler/idl_schema.py b/tools/json_schema_compiler/idl_schema.py |
index 44a4a55eaec8e06523919a621c9e450aeaa6637e..325c2bcefd3eeefb39357bc2c6c98d4e72c40b50 100644 |
--- a/tools/json_schema_compiler/idl_schema.py |
+++ b/tools/json_schema_compiler/idl_schema.py |
@@ -292,7 +292,13 @@ class Enum(object): |
enum = [] |
for node in self.node.children: |
if node.cls == 'EnumItem': |
- enum.append(node.GetName()) |
+ enum_value = {'name': node.GetName()} |
+ for child in node.children: |
+ if child.cls == 'Comment': |
+ enum_value['description'] = ProcessComment(child.GetName())[0] |
+ else: |
+ sys.exit('Did not process %s %s' % (child.cls, child)) |
not at google - send to devlin
2013/10/28 18:00:25
sys.exit to signal errors!? (aware that other plac
Sam McNally
2013/10/29 00:39:02
Done.
|
+ enum.append(enum_value) |
elif node.cls == 'Comment': |
self.description = ProcessComment(node.GetName())[0] |
else: |