From 3b10267257de7662abbbc235d9bfd8a8b89f69f5 Mon Sep 17 00:00:00 2001 From: Andrew Waterman Date: Thu, 26 May 2016 01:01:55 -0700 Subject: Fix type constraint on PriorityMux --- src/main/scala/Chisel/util/Mux.scala | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/main') diff --git a/src/main/scala/Chisel/util/Mux.scala b/src/main/scala/Chisel/util/Mux.scala index a7d835f6..9d92321a 100644 --- a/src/main/scala/Chisel/util/Mux.scala +++ b/src/main/scala/Chisel/util/Mux.scala @@ -25,9 +25,9 @@ object Mux1H */ object PriorityMux { - def apply[T <: Bits](in: Seq[(Bool, T)]): T = SeqUtils.priorityMux(in) - def apply[T <: Bits](sel: Seq[Bool], in: Seq[T]): T = apply(sel zip in) - def apply[T <: Bits](sel: Bits, in: Seq[T]): T = apply((0 until in.size).map(sel(_)), in) + def apply[T <: Data](in: Seq[(Bool, T)]): T = SeqUtils.priorityMux(in) + def apply[T <: Data](sel: Seq[Bool], in: Seq[T]): T = apply(sel zip in) + def apply[T <: Data](sel: Bits, in: Seq[T]): T = apply((0 until in.size).map(sel(_)), in) } /** MuxLookup creates a cascade of n Muxs to search for a key value */ -- cgit v1.2.3