List, Str, Mat tokens

This commit is contained in:
KikooDX 2020-05-08 10:48:22 +02:00
parent 30c2d0e6d4
commit a4683c3f72
1 changed files with 5 additions and 2 deletions

View File

@ -19,6 +19,9 @@ reserved = {
'Not': 'NOT',
'And': 'And',
'Or': 'OR',
'List': 'LIST',
'Mat': 'MAT',
'Str': 'STR',
}
literals = '+-*/%(){}[]=,'
@ -41,10 +44,10 @@ t_ISEQUAL = r'=='
t_PLUSASSIGN = r'\+='
t_MINUSASSIGN = r'\-='
t_TIMESASSIGN = r'\*='
t_DIVASSIGN = r'\/='
t_DIVASSIGN = r'/='
t_MODASSIGN = r'\%='
# Comments
t_ignore_COMMENT = r'\//.*'
t_ignore_COMMENT = r'//.*'
# A regex rule with some action code
def t_NUMBER(t):