From ce9cd802dece197d446a64d305c568f7f418d853 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= Date: Tue, 20 Jun 2017 15:42:23 +0200 Subject: [PATCH] style: Clean up after #17427. --- components/style/gecko/wrapper.rs | 4 ++-- components/style/gecko_string_cache/namespace.rs | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/components/style/gecko/wrapper.rs b/components/style/gecko/wrapper.rs index 937d1422e1d..42c9997e691 100644 --- a/components/style/gecko/wrapper.rs +++ b/components/style/gecko/wrapper.rs @@ -1747,8 +1747,8 @@ impl<'le> ::selectors::Element for GeckoElement<'le> { // If this element is the shadow root of an use-element shadow // tree, according to the spec, we should not match rules // cross the shadow DOM boundary. - e.get_local_name().as_ptr() == atom!("use").as_ptr() && - e.get_namespace() == &*Namespace(atom!("http://www.w3.org/2000/svg")) + e.get_local_name() == &*local_name!("use") && + e.get_namespace() == &*ns!("http://www.w3.org/2000/svg") }, None => false, } diff --git a/components/style/gecko_string_cache/namespace.rs b/components/style/gecko_string_cache/namespace.rs index 9368c16286f..319f15222a9 100644 --- a/components/style/gecko_string_cache/namespace.rs +++ b/components/style/gecko_string_cache/namespace.rs @@ -13,7 +13,8 @@ use string_cache::{Atom, WeakAtom}; #[macro_export] macro_rules! ns { - () => { $crate::string_cache::Namespace(atom!("")) } + () => { $crate::string_cache::Namespace(atom!("")) }; + ($s: tt) => { $crate::string_cache::Namespace(atom!($s)) }; } /// A Gecko namespace is just a wrapped atom.