From fbf5e6f1a0e8bf535d465b748ad554575fe62156 Mon Sep 17 00:00:00 2001 From: Jack Koenig Date: Sun, 22 Mar 2020 18:13:58 -0700 Subject: Rename subprojects to more canonical names * Rename coreMacros to macros * Rename chiselFrontend to core Also make each subproject publish with "chisel3-" as a prefix --- core/src/main/scala/chisel3/ModuleAspect.scala | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 core/src/main/scala/chisel3/ModuleAspect.scala (limited to 'core/src/main/scala/chisel3/ModuleAspect.scala') diff --git a/core/src/main/scala/chisel3/ModuleAspect.scala b/core/src/main/scala/chisel3/ModuleAspect.scala new file mode 100644 index 00000000..20793cd7 --- /dev/null +++ b/core/src/main/scala/chisel3/ModuleAspect.scala @@ -0,0 +1,26 @@ +// See LICENSE for license details. + +package chisel3 + +import chisel3.internal.Builder + +/** Used by Chisel Aspects to inject Chisel code into modules, after they have been elaborated. + * This is an internal API - don't use! + * + * It adds itself as an aspect to the module, which allows proper checking of connection and binding legality. + * + * @param module Module for which this object is an aspect of + * @param moduleCompileOptions + */ +abstract class ModuleAspect private[chisel3] (module: RawModule) + (implicit moduleCompileOptions: CompileOptions) extends RawModule { + + Builder.addAspect(module, this) + + override def circuitName: String = module.toTarget.circuit + + override def desiredName: String = module.name + + override val _namespace = module._namespace +} + -- cgit v1.2.3