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

Unified Diff: mojo/public/bindings/parser/mojo_parser.py

Issue 60203003: Add support for empty parameter lists. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/public/bindings/parser/mojo_parser.py
diff --git a/mojo/public/bindings/parser/mojo_parser.py b/mojo/public/bindings/parser/mojo_parser.py
index a967fbcb528b7572dab62680b4d5764642efe9d5..db13fd8d013ba37b12a262b619490ec28c60702e 100755
--- a/mojo/public/bindings/parser/mojo_parser.py
+++ b/mojo/public/bindings/parser/mojo_parser.py
@@ -185,8 +185,10 @@ class Parser(object):
"""parameters : parameter
| parameter COMMA parameters
| """
- if len(p) == 2:
- p[0] = p[1]
+ if len(p) == 1:
+ p[0] = []
+ elif len(p) == 2:
+ p[0] = ListFromConcat(p[1])
elif len(p) > 3:
p[0] = ListFromConcat(p[1], p[3])
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698