- From: Yves Lafon via cvs-syncmail <cvsmail@w3.org>
- Date: Tue, 24 Apr 2007 11:10:51 +0000
- To: www-validator-cvs@w3.org
Update of /sources/public/2002/css-validator/org/w3c/css/parser/analyzer In directory hutz:/tmp/cvs-serv17115 Modified Files: CssParser.jj Log Message: imported http://www.w3.org/Bugs/Public/attachment.cgi?id=463 in the .jj (which is used to generate the .java) Index: CssParser.jj =================================================================== RCS file: /sources/public/2002/css-validator/org/w3c/css/parser/analyzer/CssParser.jj,v retrieving revision 1.19 retrieving revision 1.20 diff -u -d -r1.19 -r1.20 --- CssParser.jj 26 Apr 2006 12:44:15 -0000 1.19 +++ CssParser.jj 24 Apr 2007 11:10:49 -0000 1.20 @@ -1959,18 +1959,19 @@ case 'a': case 'b': case 'c': case 'd': case 'e': case 'f': case 'A': case 'B': case 'C': case 'D': case 'E': case 'F': int numValue = Character.digit(c, 16); - int count = 0; + int count = 1; int p = 16; - while (index + 1 < len && count < 6) { + int maxCount = (ac.getCssVersion().equals("css1") ? 4 : 6); + while (index + 1 < len) { c = s.charAt(index+1); - if (Character.digit(c, 16) != -1) { + if (Character.digit(c, 16) != -1 && count++ < maxCount) { numValue = (numValue * 16) + Character.digit(c, 16); p *= 16; index++; } else { - if (c == ' ') { + if (c == ' ' || c == '\t' ) { // skip the latest white space index++; }
Received on Tuesday, 24 April 2007 11:10:57 UTC