From 99bb15f13491637f1c7ce58edb5ba494efc810dc Mon Sep 17 00:00:00 2001 From: Richard Lin Date: Mon, 21 Jan 2019 21:31:06 -0800 Subject: Support DontCare in Mux and cloneSupertype (#995) --- src/test/scala/chiselTests/Vec.scala | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/test/scala/chiselTests/Vec.scala') diff --git a/src/test/scala/chiselTests/Vec.scala b/src/test/scala/chiselTests/Vec.scala index 395624f7..d8e3be10 100644 --- a/src/test/scala/chiselTests/Vec.scala +++ b/src/test/scala/chiselTests/Vec.scala @@ -265,4 +265,13 @@ class VecSpec extends ChiselPropSpec { }) } } + + property("It should be possible to initialize a Vec with DontCare") { + elaborate(new Module { + val io = IO(new Bundle { + val out = Output(Vec(4, UInt(8.W))) + }) + io.out := VecInit(Seq(4.U, 5.U, DontCare, 2.U)) + }) + } } -- cgit v1.2.3