No bug - Use a static atom instead of a dynamic one. r=me
authorEmilio Cobos Álvarez <emilio@crisal.io>
Fri, 25 May 2018 14:12:44 +0200
changeset 799870 f1901407d4fae48934787c62dcb699f75ad0c60d
parent 799869 b479a3309609c69098ab05bf46e0e6c0b04d2a4e
child 799871 e5a47fceeee0bf002f521c9e35242769887cdeb0
push id111177
push userrwood@mozilla.com
push dateFri, 25 May 2018 13:40:50 +0000
reviewersme
milestone62.0a1
No bug - Use a static atom instead of a dynamic one. r=me MozReview-Commit-ID: CUTwfsCrovQ
servo/components/style/values/computed/font.rs
--- a/servo/components/style/values/computed/font.rs
+++ b/servo/components/style/values/computed/font.rs
@@ -469,17 +469,17 @@ impl SingleFontFamily {
 
         match family.mType {
             FontFamilyType::eFamily_sans_serif => SingleFontFamily::Generic(atom!("sans-serif")),
             FontFamilyType::eFamily_serif => SingleFontFamily::Generic(atom!("serif")),
             FontFamilyType::eFamily_monospace => SingleFontFamily::Generic(atom!("monospace")),
             FontFamilyType::eFamily_cursive => SingleFontFamily::Generic(atom!("cursive")),
             FontFamilyType::eFamily_fantasy => SingleFontFamily::Generic(atom!("fantasy")),
             FontFamilyType::eFamily_moz_fixed => {
-                SingleFontFamily::Generic(Atom::from("-moz-fixed"))
+                SingleFontFamily::Generic(atom!("-moz-fixed"))
             },
             FontFamilyType::eFamily_named => {
                 let name = Atom::from(&*family.mName);
                 SingleFontFamily::FamilyName(FamilyName {
                     name,
                     syntax: FamilyNameSyntax::Identifiers,
                 })
             },