chipsalliance / chipsalliance/chisel
Chisel 3.5.1 incorrectly warns on some Bundle traits
- Dominant language
- Scala
- Stars
- 4.8k
- Forks
- 658
- Avg merge
- 18h 59m
- Merged PRs (30d)
- 14
Description
**Type of issue**: bug report
**Impact**: no functional change
**Development Phase**: request | proposal
**Other information**
**If the current behavior is a bug, please provide the steps to reproduce the problem:**
It seems to happen on Bundle traits that only have virtual methods, eg.
```scala
trait Foo extends Bundle {
val foo: UInt
}
class Bar extends Foo {
val foo = UInt(8.W)
val bar = UInt(8.W)
}
class Example extends Module {
val in = IO(Input(new Bar))
val out = IO(Output(new Bar))
out := in
}
```
This seems to be due to the changes that make it possible to generate `_elementsImpl` since we know process non-concrete Bundles. That being said, this only seems to affect abstract Bundles that only have virtual methods so I don't think it affects the correctness of capturing the elements since those virtual methods will need to be implemented later.
**What is the current behavior?**
Chisel 3.5.1 warns on `trait Foo`: https://scastie.scala-lang.org/0J6M9n2URSCvzfAEnkZPcw
**What is the expected behavior?**
Chisel 3.5.0 does not: https://scastie.scala-lang.org/l1P8OyIMQ9aX3Ge22WGSEA
**Please tell us about your environment:**
Chisel v3.5.1
**What is the use case for changing the behavior?**
Contributor guide
Assessment
This issue has not been assessed yet.