diff options
| author | Jack | 2016-01-29 00:00:17 -0800 |
|---|---|---|
| committer | Jack | 2016-01-29 00:00:17 -0800 |
| commit | 676fbd9f97fcbedf351a904b645eb200c12144a5 (patch) | |
| tree | 3b89e90367e0b72ce162178839aa4add1205e53d /src/main/antlr4 | |
| parent | fec6fed92a116290c8944b34c3f9d720a1fa574d (diff) | |
Changed reg syntax to new "with" semantics in Scala FIRRTL
Diffstat (limited to 'src/main/antlr4')
| -rw-r--r-- | src/main/antlr4/FIRRTL.g4 | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/antlr4/FIRRTL.g4 b/src/main/antlr4/FIRRTL.g4 index 9d186762..2faef4e0 100644 --- a/src/main/antlr4/FIRRTL.g4 +++ b/src/main/antlr4/FIRRTL.g4 @@ -46,7 +46,7 @@ block stmt : 'wire' id ':' type - | 'reg' id ':' type exp (exp exp)? + | 'reg' id ':' type exp ('with' ':' '{' 'reset' '=>' '(' exp exp ')' '}')? | 'mem' id ':' '{' ( 'data-type' '=>' type | 'depth' '=>' IntLit | 'read-latency' '=>' IntLit @@ -97,6 +97,8 @@ id keyword : dir | 'inst' + | 'mem' + | 'reset' ; // Parentheses are added as part of name because semantics require no space between primop and open parentheses |
