-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Verilog preprocessor: implement define parameters
This implements Verilog 2001 preprocessor defines with parameters.
- Loading branch information
Showing
4 changed files
with
292 additions
and
99 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,19 @@ | ||
CORE | ||
define1.v | ||
--preprocess | ||
// Enable multi-line checking | ||
activate-multi-line-match | ||
`line 1 "define1.v" 0 | ||
|
||
|
||
|
||
value | ||
|
||
value | ||
|
||
x-y-z | ||
x-y-value | ||
^EXIT=0$ | ||
^SIGNAL=0$ | ||
-- | ||
^PREPROCESSING FAILED$ |
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,9 @@ | ||
`define basic | ||
`basic | ||
`define with_value value | ||
`with_value | ||
`define uses_previous `with_value | ||
`uses_previous | ||
`define with_parameter(a, b, c) a-b-c | ||
`with_parameter(x, y, z) | ||
`with_parameter(x, y, `with_value) |
Oops, something went wrong.