summaryrefslogtreecommitdiff
path: root/src/main/scala/chisel3/package.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/scala/chisel3/package.scala')
-rw-r--r--src/main/scala/chisel3/package.scala17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/main/scala/chisel3/package.scala b/src/main/scala/chisel3/package.scala
index cba8dffe..109bd14e 100644
--- a/src/main/scala/chisel3/package.scala
+++ b/src/main/scala/chisel3/package.scala
@@ -285,5 +285,22 @@ package object chisel3 { // scalastyle:ignore package.object.name
*/
def range(args: Any*): (NumericBound[Int], NumericBound[Int]) = macro chisel3.internal.RangeTransform.apply
}
+
+ import scala.language.experimental.macros
+ import scala.annotation.StaticAnnotation
+ import scala.annotation.compileTimeOnly
+
+ @compileTimeOnly("enable macro paradise to expand macro annotations")
+ class dump extends StaticAnnotation {
+ def macroTransform(annottees: Any*): Any = macro chisel3.internal.naming.DebugTransforms.dump
+ }
+ @compileTimeOnly("enable macro paradise to expand macro annotations")
+ class treedump extends StaticAnnotation {
+ def macroTransform(annottees: Any*): Any = macro chisel3.internal.naming.DebugTransforms.treedump
+ }
+ @compileTimeOnly("enable macro paradise to expand macro annotations")
+ class chiselName extends StaticAnnotation {
+ def macroTransform(annottees: Any*): Any = macro chisel3.internal.naming.NamingTransforms.chiselName
+ }
}
}