mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Introduce AttrValue::atom().
This commit is contained in:
parent
f010c83313
commit
4108af0c11
2 changed files with 9 additions and 2 deletions
|
@ -70,6 +70,13 @@ impl AttrValue {
|
|||
_ => None
|
||||
}
|
||||
}
|
||||
|
||||
pub fn atom<'a>(&'a self) -> Option<&'a Atom> {
|
||||
match *self {
|
||||
AttrValue::Atom(ref value) => Some(value),
|
||||
_ => None
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl Str for AttrValue {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue