mirror of
https://github.com/servo/servo.git
synced 2025-08-08 23:15:33 +01:00
Format component of style_derive
This commit is contained in:
parent
51283cf77a
commit
25bc998f17
8 changed files with 156 additions and 127 deletions
|
@ -16,12 +16,16 @@ pub fn derive(mut input: DeriveInput) -> quote::Tokens {
|
|||
);
|
||||
}
|
||||
|
||||
let to_body = cg::fmap_match(&input, BindStyle::Move, |binding| {
|
||||
quote!(::values::animated::ToAnimatedValue::to_animated_value(#binding))
|
||||
});
|
||||
let from_body = cg::fmap_match(&input, BindStyle::Move, |binding| {
|
||||
quote!(::values::animated::ToAnimatedValue::from_animated_value(#binding))
|
||||
});
|
||||
let to_body = cg::fmap_match(
|
||||
&input,
|
||||
BindStyle::Move,
|
||||
|binding| quote!(::values::animated::ToAnimatedValue::to_animated_value(#binding)),
|
||||
);
|
||||
let from_body = cg::fmap_match(
|
||||
&input,
|
||||
BindStyle::Move,
|
||||
|binding| quote!(::values::animated::ToAnimatedValue::from_animated_value(#binding)),
|
||||
);
|
||||
|
||||
input.generics.where_clause = where_clause;
|
||||
let name = &input.ident;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue