1
0

Merge pull request #508 from ucb-bar/jchang

Add iterator function to LazyModule to iterate over all nodes
This commit is contained in:
Jacob Chang 2017-01-13 10:09:50 -08:00 committed by GitHub
commit b448387899

View File

@ -85,6 +85,11 @@ abstract class LazyModule()(implicit val p: Parameters)
} } } }
children.filter(!_.omitGraphML).foreach { c => c.edgesGraphML(buf, pad) } children.filter(!_.omitGraphML).foreach { c => c.edgesGraphML(buf, pad) }
} }
def nodeIterator(iterfunc: (LazyModule) => Unit): Unit = {
iterfunc(this)
children.foreach( _.nodeIterator(iterfunc) )
}
} }
object LazyModule object LazyModule