blob: 4e37ab359867355d116aa9df20ef2aa08425d9f7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
// SPDX-License-Identifier: Apache-2.0
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
}
|