style: Inline GeckoNode::prev_sibling

It's very hot when matching some kind of selectors like the ones in bug
1717267, and the two function calls show up in the profiles.

Differential Revision: https://phabricator.services.mozilla.com/D119505
This commit is contained in:
Emilio Cobos Álvarez 2023-05-22 10:03:20 +02:00 committed by Oriol Brufau
parent 695ff236c8
commit 1918c1c203
2 changed files with 6 additions and 4 deletions

View file

@ -151,7 +151,7 @@ pub trait TNode: Sized + Copy + Clone + Debug + NodeInfo + PartialEq {
/// Get this node's first child.
fn first_child(&self) -> Option<Self>;
/// Get this node's first child.
/// Get this node's last child.
fn last_child(&self) -> Option<Self>;
/// Get this node's previous sibling.