Re: [css3-syntax] Thoughts on proposed Syntax module

A few more broader thoughts on the new syntax module:

The biggest complaints I've heard about the way parsing of CSS 2.1
is specified were:

 A.  It's not clear how the multiple levels of grammar are supposed
 to interact.

 B.  It's hard to understand how the error handling works.

 C.  The error handling isn't precisely defined.


I don't think the current draft does anything to address (A), since
it's only describing the very high-level parsing function.  I'm not
sure whether Tab's vision of the future of the spec involve
addressing the details of parsing individual at-rules and individual
property values, though.  I'm somewhat hesitant to support rewriting
the way we specify CSS parsing without addressing (A), though.

I think currently the draft does fix (B) and (C), at least as long
as its high-level grammar doesn't contradict other low-level
grammars, but I think it does so by removing the idea that there's
an underlying model behind the way CSS error handling works -- or at
least leaves enforcing that model as a job to be done by the spec
author in a very error-prone way.

I think there's value in having the underlying model behind CSS
error handling be the way it's specified.  (I'm not saying that this
is true in CSS 2.1, but I think it's closer.)  It means that we'll
stick to that model, which allows implementations that implement CSS
in ways that are vastly different from the way we implement it today
to have a better chance of being able to do so easily.  (For an
example of the kind of thing I'm thinking about, consider
implementations that do a lot of parallel computation rather than
purely sequential computation.)

-David

-- 
𝄞   L. David Baron                         http://dbaron.org/   𝄂
𝄢   Mozilla                           http://www.mozilla.org/   𝄂

Received on Wednesday, 29 August 2012 03:37:16 UTC