summaryrefslogtreecommitdiff
path: root/plugin/src/main
diff options
context:
space:
mode:
authormergify[bot]2022-04-26 00:49:16 +0000
committerGitHub2022-04-26 00:49:16 +0000
commitd5a964f6e7beea1f38f9623224fc65e2397e1fe7 (patch)
treeee1b5a7a1b8742f9cd4c96fd5430bf1dc3c9acaa /plugin/src/main
parent3e551ef38fb4c01b9b46f45dc68c2d9f5c9e9acb (diff)
Fix spurious warning from Bundle plugin (#2506) (#2507)
For traits or abstract classes that extend Bundle but have no concrete methods, the plugin will print a benign warning that the user cannot fix. It will no longer print that warning. (cherry picked from commit ed4a98188ee1fe43efbd3a1ba43a657a128764d6) Co-authored-by: Jack Koenig <koenig@sifive.com>
Diffstat (limited to 'plugin/src/main')
-rw-r--r--plugin/src/main/scala/chisel3/internal/plugin/BundleComponent.scala2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugin/src/main/scala/chisel3/internal/plugin/BundleComponent.scala b/plugin/src/main/scala/chisel3/internal/plugin/BundleComponent.scala
index d768175d..e3ec0a04 100644
--- a/plugin/src/main/scala/chisel3/internal/plugin/BundleComponent.scala
+++ b/plugin/src/main/scala/chisel3/internal/plugin/BundleComponent.scala
@@ -111,7 +111,7 @@ private[plugin] class BundleComponent(val global: Global, arguments: ChiselPlugi
override def transform(tree: Tree): Tree = tree match {
- case bundle: ClassDef if isBundle(bundle.symbol) =>
+ case bundle: ClassDef if isBundle(bundle.symbol) && !bundle.mods.hasFlag(Flag.ABSTRACT) =>
// ==================== Generate _cloneTypeImpl ====================
val (con, params) = getConstructorAndParams(bundle.impl.body)
if (con.isEmpty) {