diff options
author | Alexander Larsson <alexl@redhat.com> | 2010-07-19 16:27:42 +0200 |
---|---|---|
committer | Alexander Larsson <alexl@redhat.com> | 2010-07-19 16:28:23 +0200 |
commit | e646529d2e72ccd5b25f88adcf2c37f15c601408 (patch) | |
tree | 29dbfe2292ff56e642b1dd5bbafb0235c8b26f2e /python_modules/spice_parser.py | |
parent | 38809803807637336209a89822e12bb5f22148ca (diff) | |
download | spice-e646529d2e72ccd5b25f88adcf2c37f15c601408.tar.gz spice-e646529d2e72ccd5b25f88adcf2c37f15c601408.tar.xz spice-e646529d2e72ccd5b25f88adcf2c37f15c601408.zip |
Don't send CursorHeader if cursor_flags is NONE
Diffstat (limited to 'python_modules/spice_parser.py')
-rw-r--r-- | python_modules/spice_parser.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/python_modules/spice_parser.py b/python_modules/spice_parser.py index ac2da8dc..43e930c5 100644 --- a/python_modules/spice_parser.py +++ b/python_modules/spice_parser.py @@ -93,7 +93,7 @@ def SPICE_BNF(): variableDef = Group(typeSpec + Optional("*", default=None) + identifier + Optional(arraySizeSpec, default=None) + attributes - semi) \ .setParseAction(parseVariableDef) - switchCase = Group(Group(OneOrMore(default_.setParseAction(replaceWith(None)) + colon | case_.suppress() + identifier + colon)) + variableDef) \ + switchCase = Group(Group(OneOrMore(default_.setParseAction(replaceWith(None)) + colon | Group(case_.suppress() + Optional("!", default="") + identifier) + colon)) + variableDef) \ .setParseAction(lambda toks: ptypes.SwitchCase(toks[0][0], toks[0][1])) switchBody = Group(switch_ + lparen + delimitedList(identifier,delim='.', combine=True) + rparen + lbrace + Group(OneOrMore(switchCase)) + rbrace + identifier + attributes - semi) \ .setParseAction(lambda toks: ptypes.Switch(toks[0][1], toks[0][2], toks[0][3], toks[0][4])) |