accessibility_rs/engine/styles/errors.rs
1// use cssparser::{CowRcStr, ParseError};
2use selectors::parser::SelectorParseErrorKind;
3
4// pub type PropertyParseError<'i> = ParseError<'i, PropertyParseErrorKind<'i>>;
5
6// pub enum PropertyParseErrorKind<'i> {
7// UnknownProperty(CowRcStr<'i>),
8// UnknownUnit(CowRcStr<'i>),
9// }
10
11/// rule parsing errors
12pub enum RuleParseErrorKind<'i> {
13 /// selector parse error
14 Selector(SelectorParseErrorKind<'i>),
15}
16
17impl<'i> From<SelectorParseErrorKind<'i>> for RuleParseErrorKind<'i> {
18 fn from(e: SelectorParseErrorKind<'i>) -> Self {
19 RuleParseErrorKind::Selector(e)
20 }
21}