mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
style: Inline some things that should never ever appear in a profile.
This commit is contained in:
parent
9da7663e29
commit
2bbeda97d3
3 changed files with 13 additions and 5 deletions
|
@ -211,6 +211,7 @@ impl<'ln> GeckoNode<'ln> {
|
|||
|
||||
/// WARNING: This logic is duplicated in Gecko's FlattenedTreeParentIsParent.
|
||||
/// Make sure to mirror any modifications in both places.
|
||||
#[inline]
|
||||
fn flattened_tree_parent_is_parent(&self) -> bool {
|
||||
use gecko_bindings::structs::*;
|
||||
let flags = self.flags();
|
||||
|
@ -236,6 +237,7 @@ impl<'ln> GeckoNode<'ln> {
|
|||
true
|
||||
}
|
||||
|
||||
#[inline]
|
||||
fn flattened_tree_parent(&self) -> Option<Self> {
|
||||
let fast_path = self.flattened_tree_parent_is_parent();
|
||||
debug_assert!(fast_path == unsafe { bindings::Gecko_FlattenedTreeParentIsParent(self.0) });
|
||||
|
@ -246,6 +248,7 @@ impl<'ln> GeckoNode<'ln> {
|
|||
}
|
||||
}
|
||||
|
||||
#[inline]
|
||||
fn contains_non_whitespace_content(&self) -> bool {
|
||||
unsafe { Gecko_IsSignificantChild(self.0, true, false) }
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue