'default' is also a switch keyword.

This is academic, because 'default' is also an LSL keyword, which is why it wasn't included, but just for correctness' sake, we add it.
This commit is contained in:
Sei Lisa 2017-01-07 20:24:28 +01:00
parent 63e4425cd5
commit ab8f8a28a9

View file

@ -188,10 +188,10 @@ class parser(object):
# These are hardcoded because additions or modifications imply
# important changes to the code anyway.
base_keywords = frozenset(('default', 'state', 'event', 'jump', 'return', 'if',
'else', 'for', 'do', 'while', 'print', 'TRUE', 'FALSE'))
base_keywords = frozenset(('default', 'state', 'event', 'jump', 'return',
'if', 'else', 'for', 'do', 'while', 'print', 'TRUE', 'FALSE'))
brkcont_keywords = frozenset(('break', 'continue'))
switch_keywords = frozenset(('switch', 'case', 'break'))
switch_keywords = frozenset(('switch', 'case', 'break', 'default'))
types = frozenset(('integer','float','string','key','vector',
'quaternion','rotation','list'))
PythonType2LSL = {int: 'integer', float: 'float',