diff options
| author | Richard Lin | 2019-01-21 16:24:43 -0800 |
|---|---|---|
| committer | GitHub | 2019-01-21 16:24:43 -0800 |
| commit | 9e992816e570284193e121cd9c24503fd8cb4427 (patch) | |
| tree | 90205ab0c936d50f4853bb7dc6293a4b62d47edf /chiselFrontend/src/main/scala/chisel3/internal | |
| parent | 3b3405e8bd496749dcb47e17156c0224a6f8a496 (diff) | |
Unify internal (chisel3.core) and external (chisel3 / chisel3.experimental) Module class names (#994)
Diffstat (limited to 'chiselFrontend/src/main/scala/chisel3/internal')
| -rw-r--r-- | chiselFrontend/src/main/scala/chisel3/internal/Builder.scala | 6 | ||||
| -rw-r--r-- | chiselFrontend/src/main/scala/chisel3/internal/firrtl/IR.scala | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/chiselFrontend/src/main/scala/chisel3/internal/Builder.scala b/chiselFrontend/src/main/scala/chisel3/internal/Builder.scala index 0938ea9e..f0bb5605 100644 --- a/chiselFrontend/src/main/scala/chisel3/internal/Builder.scala +++ b/chiselFrontend/src/main/scala/chisel3/internal/Builder.scala @@ -222,8 +222,8 @@ private[chisel3] object Builder { // A bare api call is, e.g. calling Wire() from the scala console). ) } - def forcedUserModule: UserModule = currentModule match { - case Some(module: UserModule) => module + def forcedUserModule: RawModule = currentModule match { + case Some(module: RawModule) => module case _ => throwException( "Error: Not in a UserModule. Likely cause: Missed Module() wrap, bare chisel API call, or attempting to construct hardware inside a BlackBox." // A bare api call is, e.g. calling Wire() from the scala console). @@ -325,7 +325,7 @@ private[chisel3] object Builder { throwException(m) } - def build[T <: UserModule](f: => T): Circuit = { + def build[T <: RawModule](f: => T): Circuit = { chiselContext.withValue(new ChiselContext) { dynamicContextVar.withValue(Some(new DynamicContext())) { errors.info("Elaborating design...") diff --git a/chiselFrontend/src/main/scala/chisel3/internal/firrtl/IR.scala b/chiselFrontend/src/main/scala/chisel3/internal/firrtl/IR.scala index ae8b248a..c05d402d 100644 --- a/chiselFrontend/src/main/scala/chisel3/internal/firrtl/IR.scala +++ b/chiselFrontend/src/main/scala/chisel3/internal/firrtl/IR.scala @@ -286,7 +286,7 @@ abstract class Component extends Arg { def name: String def ports: Seq[Port] } -case class DefModule(id: UserModule, name: String, ports: Seq[Port], commands: Seq[Command]) extends Component +case class DefModule(id: RawModule, name: String, ports: Seq[Port], commands: Seq[Command]) extends Component case class DefBlackBox(id: BaseBlackBox, name: String, ports: Seq[Port], topDir: SpecifiedDirection, params: Map[String, Param]) extends Component case class Circuit(name: String, components: Seq[Component], annotations: Seq[ChiselAnnotation] = Seq.empty) |
