File tree Expand file tree Collapse file tree 2 files changed +9
-6
lines changed
Expand file tree Collapse file tree 2 files changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -138,6 +138,7 @@ impl<'self> SkipWhitespaceIterable<'self> for &'self [ComponentValue] {
138138 }
139139}
140140
141+ #[ deriving( Clone ) ]
141142pub struct SkipWhitespaceIterator < ' self > {
142143 iter_with_whitespace : vec:: VecIterator < ' self , ComponentValue > ,
143144}
Original file line number Diff line number Diff line change @@ -22,12 +22,14 @@ pub enum Color {
2222
2323
2424// Return None on invalid/unsupported value (not a color)
25- pub fn parse_color ( component_value : & ComponentValue ) -> Option < Color > {
26- match * component_value {
27- Hash ( ref value) | IDHash ( ref value) => parse_color_hash ( * value) ,
28- Ident ( ref value) => parse_color_keyword ( * value) ,
29- Function ( ref name, ref arguments) => parse_color_function ( * name, * arguments) ,
30- _ => None
25+ impl Color {
26+ pub fn parse ( component_value : & ComponentValue ) -> Option < Color > {
27+ match * component_value {
28+ Hash ( ref value) | IDHash ( ref value) => parse_color_hash ( * value) ,
29+ Ident ( ref value) => parse_color_keyword ( * value) ,
30+ Function ( ref name, ref arguments) => parse_color_function ( * name, * arguments) ,
31+ _ => None
32+ }
3133 }
3234}
3335
You can’t perform that action at this time.
0 commit comments