/* This Source Code Form is subject to the terms of the Mozilla Public *License,v.2.0.IfacopyoftheMPLwasnotdistributedwiththis
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
//! Various macro helpers.
macro_rules! trivial_to_computed_value {
($name:ty) => { impl $crate::values::computed::ToComputedValue for $name { type ComputedValue = $name;
/// A macro to parse an identifier, or return an `UnexpectedIdent` error /// otherwise. /// /// FIXME(emilio): The fact that `UnexpectedIdent` is a `SelectorParseError` /// doesn't make a lot of sense to me.
macro_rules! try_match_ident_ignore_ascii_case {
($input:expr, $( $match_body:tt )*) => {{ let location = $input.current_source_location(); let ident = $input.expect_ident()?;
match_ignore_ascii_case! { &ident,
$( $match_body )*
_ => return Err(location.new_custom_error(
::selectors::parser::SelectorParseErrorKind::UnexpectedIdent(ident.clone())
))
}
}}
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.