Allow dotted identifiers

This commit is contained in:
Dane Johnson 2021-11-26 11:18:35 -06:00
parent a7edad1e66
commit 5886dcd8ff
2 changed files with 5 additions and 1 deletions

4
.gitignore vendored Normal file
View File

@ -0,0 +1,4 @@
deelang
*.o
parser.h
lexer.h

View File

@ -39,7 +39,7 @@ if return IF;
else return ELSE;
elif return ELIF;
{digit}+|{digit}*\.{digit}+ yylval.num = atof(yytext); return NUM;
{letter}({letter}|{digit}|[?-])* yylval.sym = yytext; return ID;
{letter}({letter}|{digit}|[?.-])* yylval.sym = yytext; return ID;
"<-" return GETS;
"->" return MAPS;
[(){}.,*/+-] return yytext[0];