- From: Yves Lafon via cvs-syncmail <cvsmail@w3.org>
- Date: Wed, 26 Mar 2008 20:46:04 +0000
- To: www-validator-cvs@w3.org
Update of /sources/public/2002/css-validator/org/w3c/css/parser/analyzer
In directory hutz:/tmp/cvs-serv20450
Modified Files:
CssParser.jj
Log Message:
fixing hopefully for good the issue of comments
Index: CssParser.jj
===================================================================
RCS file: /sources/public/2002/css-validator/org/w3c/css/parser/analyzer/CssParser.jj,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -d -r1.33 -r1.34
--- CssParser.jj 17 Mar 2008 14:48:32 -0000 1.33
+++ CssParser.jj 26 Mar 2008 20:46:02 -0000 1.34
@@ -10,8 +10,8 @@
options {
IGNORE_CASE = true;
STATIC = false;
-/* DEBUG_TOKEN_MANAGER = true;
- DEBUG_PARSER = true; */
+/* DEBUG_TOKEN_MANAGER = true;
+ DEBUG_PARSER = true; */
}
PARSER_BEGIN(CssParser)
@@ -343,7 +343,7 @@
*/
<DEFAULT>
- MORE : /* Comments */
+ MORE :
{
< "/*" > : IN_COMMENT
}
@@ -362,6 +362,12 @@
<DEFAULT>
+SKIP :
+{
+ < #COMMENT : "/*" ( ~["*"] )* ( "*" ( ~["/"] )+ ( ~["*"] )* )* "*/" >
+}
+
+<DEFAULT>
TOKEN [IGNORE_CASE] : /* basic tokens */
{
< #H : ["0"-"9", "a"-"f"] >
@@ -373,15 +379,15 @@
| < #NMCHAR : ["a"-"z", "0"-"9", "-", "_"] | <NONASCII> | <ESCAPE> >
| < #STRING1 : "\"" ( ~[ "\n", "\r", "\f", "\\", "\"" ] | "\\" <NL> | <ESCAPE> )* "\"" >
| < #STRING2 : "\'" ( ~[ "\n", "\r", "\f", "\\", "\'" ] | "\\" <NL> | <ESCAPE> )* "\'" >
- | < #INVALID1 : "\"" ( ~[ "\n", "\r", "\f", "\\", "\"" ] | "\\" <NL> | <ESCAPE> )* >
+ | < #INVALID1 : "\"" ( ~[ "\n", "\r", "\f", "\\", "\"" ] | "\\" <NL> | <ESCAPE> )* >
| < #INVALID2 : "\'" ( ~[ "\n", "\r", "\f", "\\", "\'" ] | "\\" <NL> | <ESCAPE> )* >
| < #_IDENT : ( <MINUS> )? <NMSTART> ( <NMCHAR> )* >
| < #NAME : ( <NMCHAR> )+ >
| < #NUM : ( ["0"-"9"] )+ | ( ["0"-"9"] )* "." ( ["0"-"9"] )+ >
| < #_STRING : <STRING1> | <STRING2> >
- | < #_INVALID : <INVALID1> | <INVALID2> >
+ | < #_INVALID : <INVALID1> | <INVALID2> >
| < #_URL : ( [ "!", "#", "$", "%", "&", "*", "+", "-"-"[", "]"-"~" ] | <NONASCII> | <ESCAPE> )* >
- | < #_S : ( [ " ", "\t" , "\n" , "\r", "\f" ] )+ >
+ | < #_S : ( [ " ", "\t" , "\n" , "\r", "\f" ] ( <COMMENT> )? )+ >
| < #_W : ( <_S> )? >
| < #NL : ( "\n" | "\r\n" | "\r" | "\f" ) >
}
@@ -1095,7 +1101,7 @@
( ( <PLUS> { connector = '+' ; }
| <GREATER> { connector = '>' ; }
| <TILDE> { connector = '~' ; }
- ) ( <S> )*
+ ) ( <S> )*
| ( <S> )+ { connector = ' ' ; }
)
{
@@ -1129,7 +1135,7 @@
*/
void ruleSet() :
{ CssSelectors contextual;
- Vector context_set = new Vector();
+ Vector<CssSelectors> context_set = new Vector<CssSelectors>();
Vector value_set = null;
currentContext = context_set;
}
Received on Wednesday, 26 March 2008 20:46:36 UTC