diff options
Diffstat (limited to 'src/test/scala/chiselTests/RecordSpec.scala')
| -rw-r--r-- | src/test/scala/chiselTests/RecordSpec.scala | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/test/scala/chiselTests/RecordSpec.scala b/src/test/scala/chiselTests/RecordSpec.scala index 3358d506..d17ff9bd 100644 --- a/src/test/scala/chiselTests/RecordSpec.scala +++ b/src/test/scala/chiselTests/RecordSpec.scala @@ -24,7 +24,8 @@ trait RecordSpecUtils { override def cloneType = (new MyBundle).asInstanceOf[this.type] } // Useful for constructing types from CustomBundle - val fooBarType = new CustomBundle("foo" -> UInt(32.W), "bar" -> UInt(32.W)) + // This is a def because each call to this needs to return a new instance + def fooBarType = new CustomBundle("foo" -> UInt(32.W), "bar" -> UInt(32.W)) class MyModule(output: => Record, input: => Record) extends Module { val io = IO(new Bundle { |
