Fix parsing of hierarchical identifiers
the lexor didn't allow numbers in the IDENTIFIER name, and the parser wasn't very nice with IDENTIFIER errors. Signed-off-by: Stephen Williams <steve@icarus.com>
This commit is contained in:
parent
2a269f1bb7
commit
26f1d50248
|
|
@ -65,7 +65,7 @@ static int yywrap(void)
|
|||
return REAL_NUMBER;
|
||||
}
|
||||
|
||||
[a-zA-Z]+ {
|
||||
[a-zA-Z][a-zA-Z0-9]* {
|
||||
return lookup_keyword(yytext);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -198,6 +198,10 @@ cell_instance
|
|||
{ $$ = strdup(""); }
|
||||
| '(' K_INSTANCE '*' ')'
|
||||
{ $$ = 0; }
|
||||
| '(' K_INSTANCE error ')'
|
||||
{ vpi_printf("%s:%d:SDF ERROR: Invalid/malformed INSTANCE argument\n",
|
||||
sdf_parse_path, @2.first_line);
|
||||
$$ = strdup(""); }
|
||||
;
|
||||
|
||||
timing_spec_list
|
||||
|
|
|
|||
Loading…
Reference in New Issue