mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Introduce #[css(skip)]
This commit is contained in:
parent
7931df716d
commit
ca45695db1
8 changed files with 31 additions and 96 deletions
|
@ -26,10 +26,12 @@ use std::fmt::{self, Write};
|
|||
/// serialised like unit variants and its fields are surrounded by parentheses;
|
||||
/// * if `#[css(iterable)]` is found on a function variant, that variant needs
|
||||
/// to have a single member, and that member needs to be iterable. The
|
||||
/// iterable will be serialized as the arguments for the function.
|
||||
/// iterable will be serialized as the arguments for the function;
|
||||
/// * if `#[css(dimension)]` is found on a variant, that variant needs
|
||||
/// to have a single member. The variant would be serialized as a CSS
|
||||
/// dimension token, like: <member><identifier>.
|
||||
/// dimension token, like: <member><identifier>;
|
||||
/// * if `#[css(skip)]` is found on a field, the `ToCss` call for that field
|
||||
/// is skipped;
|
||||
/// * finally, one can put `#[css(derive_debug)]` on the whole type, to
|
||||
/// implement `Debug` by a single call to `ToCss::to_css`.
|
||||
pub trait ToCss {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue