mirror of
https://github.com/YosysHQ/yosys
synced 2025-04-23 00:55:32 +00:00
Merge pull request #1943 from YosysHQ/dave/fix-1919
ast: Fix handling of identifiers in the global scope
This commit is contained in:
commit
2b57c06360
3 changed files with 25 additions and 2 deletions
18
tests/various/global_scope.ys
Normal file
18
tests/various/global_scope.ys
Normal file
|
@ -0,0 +1,18 @@
|
|||
read_verilog -sv <<EOT
|
||||
parameter A = 10;
|
||||
parameter B = A;
|
||||
|
||||
typedef enum {
|
||||
CONST_A = A,
|
||||
CONST_B = A+1
|
||||
} enum_t;
|
||||
|
||||
module top(output [3:0] q, output [3:0] r);
|
||||
assign q = 10;
|
||||
assign r = CONST_B;
|
||||
endmodule
|
||||
EOT
|
||||
|
||||
hierarchy -top top
|
||||
sat -verify -prove q 10 top
|
||||
sat -verify -prove r 11 top
|
Loading…
Add table
Add a link
Reference in a new issue