Skip to content

Commit

Permalink
[gcd] fix arg name in elaborator
Browse files Browse the repository at this point in the history
Signed-off-by: unlsycn <[email protected]>
  • Loading branch information
unlsycn committed Sep 11, 2024
1 parent d30d3e5 commit 2482227
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions templates/chisel/elaborator/src/GCD.scala
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ import org.chipsalliance.gcd.elaborator.Elaborator
object GCDMain extends Elaborator {
@main
case class GCDParameterMain(
@arg(name = "xLen") xLen: Int,
@arg(name = "width") width: Int,
@arg(name = "useAsyncReset") useAsyncReset: Boolean) {
require(xLen > 0, "xLen must be a non-negative integer")
require(chisel3.util.isPow2(xLen), "xLen must be a power of 2")
def convert: GCDParameter = GCDParameter(xLen, useAsyncReset)
require(width > 0, "width must be a non-negative integer")
require(chisel3.util.isPow2(width), "width must be a power of 2")
def convert: GCDParameter = GCDParameter(width, useAsyncReset)
}

implicit def GCDParameterMainParser: ParserForClass[GCDParameterMain] =
Expand Down

0 comments on commit 2482227

Please sign in to comment.