Re: [CSS21] [css3-syntax] Blocks in parentheses or brackets

Bert Bos wrote [G]:

 > Etan Wexler writes:
 >> the formal grammar, in which a
 >> block is forbidden inside parentheses and inside brackets. At
 >> issue is the following production
 >> (<http://www.w3.org/TR/1998/REC-CSS2-19980512/grammar.html>,
 >> <http://www.w3.org/TR/2003/WD-CSS21-20030128/grammar.html>).
 >>
 >> any         : [ IDENT | NUMBER | PERCENTAGE | DIMENSION | STRING
 >>               | DELIM | URI | HASH | UNICODE-RANGE | INCLUDES
 >>               | FUNCTION | DASHMATCH | '(' any* ')' | '[' any* ']' ] 
S*;
 >
 > You should distinguish the grammar of appendix D (the one you quoted)
 > from the grammar in chapter 4. The former is an approximation of the
 > grammar of CSS level 2 *only*, while the latter is for all of CSS.

Yet the grammar in chapter 4 [F] makes the same mistake:

any         : [ IDENT | NUMBER | PERCENTAGE | DIMENSION | STRING
               | DELIM | URI | HASH | UNICODE-RANGE | INCLUDES
               | DASHMATCH | FUNCTION S* any* ')'
               | '(' S* any* ')' | '[' S* any* ']' ] S*;

And the CSS3 Syntax module [S] continues the trend:

any         : [ IDENT | NUMBER | PERCENTAGE | DIMENSION | STRING
               | DELIM | URI | HASH | UNICODE-RANGE | INCLUDES
               | FUNCTION S* any* ')' | DASHMATCH | '(' S* any* ')'
               | '[' S* any* ']' ] S*;

---

[G]
Bert Bos.
"Re: Blocks in parentheses or brackets".
2003-02-21.
Message to <mailto:www-style@w3.org>.
<mid:15958.9863.624296.392437@lanalana.inria.fr>.

[F]
Bert Bos; and others.
"Tokenization", section 4.1.1 of the CSS 2.1 specification.
2003-09-15.
W3C Last Call Working Draft.
<http://www.w3.org/TR/2003/WD-CSS21-20030915/syndata.html#tokenization>.

[S]
L. David Baron, editor.
"Grammar", section 4.3 of the CSS3 Syntax specification.
2003-08-13.
W3C Working Draft.
<http://www.w3.org/TR/2003/WD-css3-syntax-20030813/#grammar>.

Received on Friday, 28 November 2003 18:33:55 UTC