Skip rule node which contains only inherited properties for rule cache.

This commit is contained in:
Xidorn Quan 2018-01-05 09:54:59 +11:00
parent 782e3fe4e4
commit 3593392788
6 changed files with 75 additions and 7 deletions

View file

@ -864,7 +864,8 @@ impl StrongRuleNode {
WeakRuleNode::from_ptr(self.ptr())
}
fn parent(&self) -> Option<&StrongRuleNode> {
/// Get the parent rule node of this rule node.
pub fn parent(&self) -> Option<&StrongRuleNode> {
self.get().parent.as_ref()
}