mirror of
https://github.com/servo/servo.git
synced 2025-08-07 14:35:33 +01:00
style: Stop copying attribute names when looking them up in the hash
table. 40% improvement in selector matching performance on the rainbow page.
This commit is contained in:
parent
6ee9f8a982
commit
984e6b853d
1 changed files with 1 additions and 1 deletions
|
@ -120,7 +120,7 @@ impl SelectorMap {
|
||||||
hash: &HashMap<~str,~[Rule]>,
|
hash: &HashMap<~str,~[Rule]>,
|
||||||
key: &str,
|
key: &str,
|
||||||
matching_rules: &mut ~[Rule]) {
|
matching_rules: &mut ~[Rule]) {
|
||||||
match hash.find(&key.to_str()) {
|
match hash.find_equiv(&key) {
|
||||||
Some(rules) => {
|
Some(rules) => {
|
||||||
SelectorMap::get_matching_rules(node, *rules, matching_rules)
|
SelectorMap::get_matching_rules(node, *rules, matching_rules)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue