Re: Malformed declarations incorrectly parsed?

Yves Lafon wrote:
> Yes, in case of error, the current behaviour is to skip until a matching 
> brace. This might be changed in the future, but is part of a more 
> general discussion about: "Should a _validator_ do error recovery like 
> other UA like browsers, or not? The same apply for the examples below.

Whatever the tool does needs to be consistent and explained. From the 
erroneous input:

p {unknown: red; color: green;}

The validator extracts color: green; as valid CSS information, rather 
than dropping the rule set.

In the spec examples:

(a) p { color:green; color }

(b) p { color:green; color: }

(c) p { color:red;   color:; color:green }

It does not drop the entire rule set, but instead reports color: green; 
in all cases and color: red; in (c).

Benjamin Hawkes-Lewis

Received on Friday, 14 March 2008 11:18:12 UTC