summaryrefslogtreecommitdiff
path: root/src/main/scala/chisel/util/Conditional.scala
diff options
context:
space:
mode:
authorducky2016-05-27 13:24:36 -0700
committerducky2016-06-08 16:22:27 -0700
commit881ac3cb3a9da0c7827a161238468df4727996f0 (patch)
tree865b929b176ab1fd2c08fb4b7a083cdc2d132820 /src/main/scala/chisel/util/Conditional.scala
parent671117f3332ac10d1e7c5cc4f4cb5278f72ed6ab (diff)
Move utils into utils
Diffstat (limited to 'src/main/scala/chisel/util/Conditional.scala')
-rw-r--r--src/main/scala/chisel/util/Conditional.scala6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/main/scala/chisel/util/Conditional.scala b/src/main/scala/chisel/util/Conditional.scala
index 94f00080..01c12799 100644
--- a/src/main/scala/chisel/util/Conditional.scala
+++ b/src/main/scala/chisel/util/Conditional.scala
@@ -3,13 +3,15 @@
/** Conditional blocks.
*/
-package chisel
+package chisel.util
import scala.language.reflectiveCalls
import scala.language.experimental.macros
import scala.reflect.runtime.universe._
import scala.reflect.macros.blackbox._
+import chisel._
+
/** This is identical to [[Chisel.when when]] with the condition inverted */
object unless { // scalastyle:ignore object.name
def apply(c: Bool)(block: => Unit) {
@@ -61,7 +63,7 @@ object switch { // scalastyle:ignore object.name
def extractIsStatement(tree: Tree): List[c.universe.Tree] = tree match {
// TODO: remove when Chisel compatibility package is removed
case q"Chisel.`package`.is.apply( ..$params )( ..$body )" => List(q"$sc.is( ..$params )( ..$body )")
- case q"chisel.is.apply( ..$params )( ..$body )" => List(q"$sc.is( ..$params )( ..$body )")
+ case q"chisel.util.is.apply( ..$params )( ..$body )" => List(q"$sc.is( ..$params )( ..$body )")
case b => throw new Exception(s"Cannot include blocks that do not begin with is() in switch.")
}
val q"..$body" = x