diff --git a/src/lexer.py b/src/lexer.py index cb6e149..8e16636 100644 --- a/src/lexer.py +++ b/src/lexer.py @@ -15,9 +15,7 @@ tokens = [ "INF", "NAN", "COMMENT", - ] - - +] # needs to check if datetime is valid @@ -37,19 +35,6 @@ def t_TIME(t): r"\d{2}:\d{2}:\d{2}(\.\d{1,6})?" return t -# ID needs to be the last so it doesnt catch everything (literally) -def t_ID(t): - r"(([\w_]+)|(\"[\w_]+\"\.|\'[\w_]+\'\.)([\w_]+|\"[\w_]+\"|\'[\w_]+\'))(\.([\w_]+|\"[\w_]+\"|\'[\w_]+\'))*" - return t - -def t_MLSTR(t): - r"(\"\"\"(?:[^\"\\]|\\.)+\"\"\")|(\'\'\'(?:[^\'\\]|\\.)+\'\'\')" - return t - -# STR needs to be the first one to catch -def t_STR(t): - r"(?