Consistently use dominates instead of is_dominated_by
There is a number of APIs that answer dominance queries. Previously they were named either "dominates" or "is_dominated_by". Consistently use the "dominates" form. No functional changes.
This commit is contained in:
@@ -289,7 +289,7 @@ impl<Node: Idx> Dominators<Node> {
|
||||
Iter { dominators: self, node: Some(node) }
|
||||
}
|
||||
|
||||
pub fn is_dominated_by(&self, node: Node, dom: Node) -> bool {
|
||||
pub fn dominates(&self, dom: Node, node: Node) -> bool {
|
||||
// FIXME -- could be optimized by using post-order-rank
|
||||
self.dominators(node).any(|n| n == dom)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user