mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Make AttrValue::as_slice impl from Str
This commit is contained in:
parent
608389132a
commit
9061942664
1 changed files with 4 additions and 1 deletions
|
@ -56,7 +56,10 @@ impl AttrValue {
|
||||||
AtomAttrValue(value)
|
AtomAttrValue(value)
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn as_slice<'a>(&'a self) -> &'a str {
|
}
|
||||||
|
|
||||||
|
impl Str for AttrValue {
|
||||||
|
fn as_slice<'a>(&'a self) -> &'a str {
|
||||||
match *self {
|
match *self {
|
||||||
StringAttrValue(ref value) |
|
StringAttrValue(ref value) |
|
||||||
TokenListAttrValue(ref value, _) |
|
TokenListAttrValue(ref value, _) |
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue