diff options
author | Clifford Wolf <clifford@clifford.at> | 2017-01-17 17:33:52 +0100 |
---|---|---|
committer | Clifford Wolf <clifford@clifford.at> | 2017-01-17 17:33:52 +0100 |
commit | fea528280b9e598ae13178c9ce4ac16e569c46a8 (patch) | |
tree | ee57bb36d70aad6de23f36536905369a20471976 /frontends/verilog/verilog_lexer.l | |
parent | 78f65f89ffc1d5c5237009c19e84e625ce3085aa (diff) | |
download | yosys-fea528280b9e598ae13178c9ce4ac16e569c46a8.tar.gz yosys-fea528280b9e598ae13178c9ce4ac16e569c46a8.tar.bz2 yosys-fea528280b9e598ae13178c9ce4ac16e569c46a8.zip |
Add "enum" and "typedef" lexer support
Diffstat (limited to 'frontends/verilog/verilog_lexer.l')
-rw-r--r-- | frontends/verilog/verilog_lexer.l | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/frontends/verilog/verilog_lexer.l b/frontends/verilog/verilog_lexer.l index 405aeb975..c22fdf39c 100644 --- a/frontends/verilog/verilog_lexer.l +++ b/frontends/verilog/verilog_lexer.l @@ -192,6 +192,9 @@ YOSYS_NAMESPACE_END "genvar" { return TOK_GENVAR; } "real" { return TOK_REAL; } +"enum" { SV_KEYWORD(TOK_ENUM); } +"typedef" { SV_KEYWORD(TOK_TYPEDEF); } + [0-9][0-9_]* { frontend_verilog_yylval.string = new std::string(yytext); return TOK_CONST; |