From 0b62c3a7c7548cd447b4f18e0346cc9e74862ab3 Mon Sep 17 00:00:00 2001 From: Martin Mares Date: Fri, 27 Nov 1998 21:32:45 +0000 Subject: Trivial 15-line bison excercise: Implemented expressions including user-defined numeric symbols. Whenever possible, use `expr' instead of `NUM' to get full express ion power :-) --- conf/cf-lex.l | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'conf/cf-lex.l') diff --git a/conf/cf-lex.l b/conf/cf-lex.l index f653bca..66f3038 100644 --- a/conf/cf-lex.l +++ b/conf/cf-lex.l @@ -101,7 +101,7 @@ WHITE [ \t] return SYM; } -[{}:;,] { +[={}:;,()+*/%-] { return yytext[0]; } @@ -177,6 +177,7 @@ cf_find_sym(byte *c, unsigned int h0) sym_hash[h] = s; s->class = SYM_VOID; s->def = NULL; + s->aux = 0; strcpy(s->name, c); return s; } -- cgit v1.2.3