mirror of
https://github.com/servo/servo.git
synced 2025-08-06 06:00:15 +01:00
style: Inline some trivial bits.
Bug: 1466963 Reviewed-by: xidorn MozReview-Commit-ID: A219QehiMqZ
This commit is contained in:
parent
255fe05d40
commit
9c51d31b05
2 changed files with 4 additions and 0 deletions
|
@ -8,6 +8,7 @@ use context::QuirksMode;
|
|||
use gecko_bindings::structs::nsCompatibility;
|
||||
|
||||
impl From<nsCompatibility> for QuirksMode {
|
||||
#[inline]
|
||||
fn from(mode: nsCompatibility) -> QuirksMode {
|
||||
match mode {
|
||||
nsCompatibility::eCompatibility_FullStandards => QuirksMode::NoQuirks,
|
||||
|
|
|
@ -593,18 +593,21 @@ impl NonCustomPropertyId {
|
|||
}
|
||||
|
||||
impl From<LonghandId> for NonCustomPropertyId {
|
||||
#[inline]
|
||||
fn from(id: LonghandId) -> Self {
|
||||
NonCustomPropertyId(id as usize)
|
||||
}
|
||||
}
|
||||
|
||||
impl From<ShorthandId> for NonCustomPropertyId {
|
||||
#[inline]
|
||||
fn from(id: ShorthandId) -> Self {
|
||||
NonCustomPropertyId((id as usize) + ${len(data.longhands)})
|
||||
}
|
||||
}
|
||||
|
||||
impl From<AliasId> for NonCustomPropertyId {
|
||||
#[inline]
|
||||
fn from(id: AliasId) -> Self {
|
||||
NonCustomPropertyId(id as usize + ${len(data.longhands) + len(data.shorthands)})
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue