mirror of
https://github.com/servo/servo.git
synced 2025-08-07 06:25:32 +01:00
style: Make the will-change bitfield use cbindgen.
Differential Revision: https://phabricator.services.mozilla.com/D23414
This commit is contained in:
parent
6e2643c636
commit
01e0f37861
4 changed files with 14 additions and 33 deletions
|
@ -102,20 +102,3 @@ macro_rules! define_keyword_type {
|
|||
}
|
||||
};
|
||||
}
|
||||
|
||||
#[cfg(feature = "gecko")]
|
||||
macro_rules! impl_bitflags_conversions {
|
||||
($name:ident) => {
|
||||
impl From<u8> for $name {
|
||||
fn from(bits: u8) -> $name {
|
||||
$name::from_bits(bits).expect("bits contain valid flag")
|
||||
}
|
||||
}
|
||||
|
||||
impl From<$name> for u8 {
|
||||
fn from(v: $name) -> u8 {
|
||||
v.bits()
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue