Merge pull request #1008 from tschaub/code-gen

Non-greedy pattern matching for types.
This commit is contained in:
Tim Schaub
2013-09-10 23:13:55 -07:00

View File

@@ -300,7 +300,7 @@ def main(argv):
object_literal = ObjectLiteral(name, objects)
objects[name] = object_literal
continue
m = re.match(r'\*\s*@property\s*{(?P<type>.*)}\s*(?P<prop>\S+)', line)
m = re.match(r'\*\s*@property\s*{(?P<type>.*?)}\s*(?P<prop>\S+)', line)
if m:
assert object_literal is not None
prop = m.group('prop')