summaryrefslogtreecommitdiff
path: root/src/test/scala/chiselTests/When.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/scala/chiselTests/When.scala')
-rw-r--r--src/test/scala/chiselTests/When.scala11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/test/scala/chiselTests/When.scala b/src/test/scala/chiselTests/When.scala
index a6572706..6dc2dbac 100644
--- a/src/test/scala/chiselTests/When.scala
+++ b/src/test/scala/chiselTests/When.scala
@@ -3,14 +3,17 @@
package chiselTests
import org.scalatest._
-import Chisel._
-import Chisel.testers.BasicTester
+
+import chisel3._
+import chisel3.testers.BasicTester
+import chisel3.util._
+//import chisel3.core.ExplicitCompileOptions.Strict
class WhenTester() extends BasicTester {
val cnt = Counter(4)
when(Bool(true)) { cnt.inc() }
- val out = Wire(UInt(width=3))
+ val out = Wire(UInt.width(3))
when(cnt.value === UInt(0)) {
out := UInt(1)
} .elsewhen (cnt.value === UInt(1)) {
@@ -32,7 +35,7 @@ class OverlappedWhenTester() extends BasicTester {
val cnt = Counter(4)
when(Bool(true)) { cnt.inc() }
- val out = Wire(UInt(width=3))
+ val out = Wire(UInt.width(3))
when(cnt.value <= UInt(0)) {
out := UInt(1)
} .elsewhen (cnt.value <= UInt(1)) {