-
Notifications
You must be signed in to change notification settings - Fork 91
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix apostrophe parser in auto wire (#1854)
- Loading branch information
dong
committed
Jan 9, 2024
1 parent
21a1000
commit 4e06566
Showing
2 changed files
with
82 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
module test_port0 | ||
(/*AUTOARG*/); | ||
output [31:0] d[2]; | ||
endmodule // test_port | ||
|
||
module test_port1 | ||
(/*AUTOARG*/); | ||
input [31:0] dd[2]; | ||
endmodule // test_port1 | ||
|
||
module top() | ||
/*AUTOWIRE*/ | ||
|
||
/* | ||
test_port0 AUTO_TEMPLATE | ||
( | ||
.d\(.*\) ('{d_1\1[],d_2\1[]}), | ||
); | ||
*/ | ||
test_port0 | ||
u0(/*AUTOINST*/); | ||
|
||
/* | ||
test_port1 AUTO_TEMPLATE | ||
( | ||
.d\(.*\) ('{d_1\1[],d_2\1[]}), | ||
); | ||
*/ | ||
|
||
test_port1 | ||
u1(/*AUTOINST*/); | ||
endmodule // top | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
module test_port0 | ||
(/*AUTOARG*/ | ||
// Outputs | ||
d | ||
); | ||
output [31:0] d[2]; | ||
endmodule // test_port | ||
|
||
module test_port1 | ||
(/*AUTOARG*/ | ||
// Inputs | ||
dd | ||
); | ||
input [31:0] dd[2]; | ||
endmodule // test_port1 | ||
|
||
module top() | ||
/*AUTOWIRE*/ | ||
// Beginning of automatic wires (for undeclared instantiated-module outputs) | ||
wire [31:0] d_1; // From u0 of test_port0.v | ||
wire [31:0] d_2; // From u0 of test_port0.v | ||
// End of automatics | ||
|
||
/* | ||
test_port0 AUTO_TEMPLATE | ||
( | ||
.d\(.*\) ('{d_1\1[],d_2\1[]}), | ||
); | ||
*/ | ||
test_port0 | ||
u0(/*AUTOINST*/ | ||
// Outputs | ||
.d ('{d_1[31:0],d_2[31:0]})); // Templated | ||
|
||
/* | ||
test_port1 AUTO_TEMPLATE | ||
( | ||
.d\(.*\) ('{d_1\1[],d_2\1[]}), | ||
); | ||
*/ | ||
|
||
test_port1 | ||
u1(/*AUTOINST*/ | ||
// Inputs | ||
.dd ('{d_1d[31:0],d_2d[31:0]})); // Templated | ||
endmodule // top | ||
|
||
|