File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2172,11 +2172,15 @@ range: part_select;
21722172
21732173net_decl_assignment:
21742174 net_identifier unpacked_dimension_brace
2175- { $$ = $1 ;
2175+ { // add to the scope
2176+ PARSER.scopes .add_identifier (stack_expr ($1 ).get (ID_base_name), verilog_scopet::NET);
2177+ $$ = $1 ;
21762178 stack_expr ($$).id (ID_declarator);
21772179 addswap ($$, ID_type, $2 ); }
21782180 | net_identifier unpacked_dimension_brace ' =' expression
2179- { $$ = $1 ;
2181+ { // add to the scope
2182+ PARSER.scopes .add_identifier (stack_expr ($1 ).get (ID_base_name), verilog_scopet::NET);
2183+ $$ = $1 ;
21802184 stack_expr ($$).id (ID_declarator);
21812185 addswap ($$, ID_type, $2 );
21822186 addswap ($$, ID_value, $4 ); }
Original file line number Diff line number Diff line change @@ -93,6 +93,7 @@ unsigned verilog_scopet::identifier_token() const
9393 case verilog_scopet::PARAMETER: return TOK_NON_TYPE_IDENTIFIER;
9494 case verilog_scopet::PROPERTY: return TOK_NON_TYPE_IDENTIFIER;
9595 case verilog_scopet::SEQUENCE: return TOK_NON_TYPE_IDENTIFIER;
96+ case verilog_scopet::NET: return TOK_NON_TYPE_IDENTIFIER;
9697 case verilog_scopet::VAR: return TOK_NON_TYPE_IDENTIFIER;
9798 case verilog_scopet::OTHER: return TOK_NON_TYPE_IDENTIFIER;
9899 // clang-format on
Original file line number Diff line number Diff line change @@ -32,6 +32,7 @@ struct verilog_scopet
3232 PARAMETER,
3333 PROPERTY,
3434 SEQUENCE,
35+ NET,
3536 VAR,
3637 OTHER
3738 };
You can’t perform that action at this time.
0 commit comments