CSS2 core syntax

Hi,

The grammar for the CSS2 core syntax appears to be incorrect:

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

Note that the production for any contains FUNCTION, which is defined as:

	FUNCTION {ident}\(

However there is no way to match the arguments and closing bracket of the 
function, making the grammar break for cases like this:

	@example foo(bar, "baz");

This could be corrected by replacing the reference to FUNCTION in the any 
production with:

	FUNCTION S* any [ ',' any ]* ')'

Any thoughts?

Michael

Received on Tuesday, 18 February 2003 04:38:50 UTC