diff options
| author | chick | 2016-09-23 16:43:22 -0700 |
|---|---|---|
| committer | Donggyu Kim | 2016-09-25 14:39:44 -0700 |
| commit | 93b5002cc18315b1872253926c3b383962bbb2d2 (patch) | |
| tree | 32db7158b180e188e19f36ee91dc55975f98fc28 /src/main/scala/firrtl/Utils.scala | |
| parent | 1f168585c80d5c96e41353d6275d99b34b967b23 (diff) | |
stuff like this mutable.LinkedHashMap needs the mutable prefix
Diffstat (limited to 'src/main/scala/firrtl/Utils.scala')
| -rw-r--r-- | src/main/scala/firrtl/Utils.scala | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/main/scala/firrtl/Utils.scala b/src/main/scala/firrtl/Utils.scala index 685e0a9e..453e9a0c 100644 --- a/src/main/scala/firrtl/Utils.scala +++ b/src/main/scala/firrtl/Utils.scala @@ -41,6 +41,7 @@ import firrtl.PrimOps._ import firrtl.Mappers._ import firrtl.WrappedExpression._ import firrtl.WrappedType._ +import scala.collection.mutable import scala.collection.mutable.{StringBuilder, ArrayBuffer, LinkedHashMap, HashMap, HashSet} import java.io.PrintWriter import com.typesafe.scalalogging.LazyLogging @@ -144,6 +145,7 @@ object Utils extends LazyLogging { } /** Returns true if t, or any subtype, contains a flipped field + * * @param t type [[firrtl.ir.Type]] to be checked * @return if t contains [[firrtl.ir.Flip]] */ @@ -523,7 +525,7 @@ class MemoizedHash[T](val t: T) { * The graph is a map between the name of a node to set of names of that nodes children */ class ModuleGraph { - val nodes = HashMap[String, HashSet[String]]() + val nodes = mutable.HashMap[String, mutable.HashSet[String]]() /** * Add a child to a parent node @@ -534,7 +536,7 @@ class ModuleGraph { * @return a list indicating a path from child to parent, empty if no such path */ def add(parent: String, child: String): List[String] = { - val childSet = nodes.getOrElseUpdate(parent, new HashSet[String]) + val childSet = nodes.getOrElseUpdate(parent, new mutable.HashSet[String]) childSet += child pathExists(child, parent, List(child, parent)) } |
