File tree Expand file tree Collapse file tree 3 files changed +17
-4
lines changed
Expand file tree Collapse file tree 3 files changed +17
-4
lines changed Original file line number Diff line number Diff line change 22
33package chisel3
44
5- /** Does nothing in Scala 2; this stub trait is for maintaining
6- * compatibility with Scala 3's selectable, required to support
7- * structurally-typed Bundles in Scala 3.
5+ /** Shim for Scala 3's `scala.reflect.Selectable`
6+ *
7+ * Allows Chisel to cross-compile Scala 2 and Scala 3
8+ * while enabling structural typing in Scala 3.
9+ */
10+ trait ReflectSelectable
11+
12+ /** Shim for Scala 3's `scala.Selectable`
13+ *
14+ * Allows Chisel to cross-compile Scala 2 and Scala 3
15+ * while enabling structural typing in Scala 3.
816 */
917trait Selectable
Original file line number Diff line number Diff line change 1+ // SPDX-License-Identifier: Apache-2.0
2+
3+ package chisel3
4+
5+ type ReflectSelectable = scala.reflect.Selectable
Original file line number Diff line number Diff line change @@ -413,7 +413,7 @@ package experimental {
413413 /** Abstract base class for Modules, an instantiable organizational unit for RTL.
414414 */
415415 // TODO: seal this?
416- abstract class BaseModule extends HasId with IsInstantiable {
416+ abstract class BaseModule extends HasId with IsInstantiable with ReflectSelectable {
417417 _parent.foreach(_.addId(this ))
418418
419419 // Set if the returned top-level module of a nested call to the Chisel Builder, see Definition.apply
You can’t perform that action at this time.
0 commit comments