This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 5718 - Problem validating CSS files with UTF-8 characters
Summary: Problem validating CSS files with UTF-8 characters
Status: RESOLVED FIXED
Alias: None
Product: CSSValidator
Classification: Unclassified
Component: CSS 2.1 (show other bugs)
Version: CSS Validator
Hardware: PC Windows XP
: P2 normal
Target Milestone: ---
Assignee: This bug has no owner yet - up for the taking
QA Contact: qa-dev tracking
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-05-27 14:02 UTC by Radu Coravu
Modified: 2009-02-17 22:16 UTC (History)
0 users

See Also:


Attachments
CSS file with UNICODE character 010D (136 bytes, text/css)
2008-05-27 14:03 UTC, Radu Coravu
Details
XML file (147 bytes, text/xml)
2008-05-27 14:04 UTC, Radu Coravu
Details

Description Radu Coravu 2008-05-27 14:02:49 UTC
As far as I can see in the specification CSS files can contain all possible Unicode characters if the "@charset" declaration in them allows that.

There seem to be 2 problems in the CssParser.jj file.
First, in the options{} block you should set the "UNICODE_INPUT = true;" property so that the parser can handle unicode chars if the reader was correctly built.
Then, the NONASCII token should probably be declared as:  ~["\000"-"\177"]
This means anything but ASCII.

I will try to attach 2 test files. The XML is correctly displayed in Firefox but the validator complains about the CSS file
Comment 1 Radu Coravu 2008-05-27 14:03:49 UTC
Created attachment 552 [details]
CSS file with UNICODE character 010D
Comment 2 Radu Coravu 2008-05-27 14:04:01 UTC
Created attachment 553 [details]
XML file
Comment 3 Yves Lafon 2009-02-17 22:16:30 UTC
Should be fixed by recent updates on the @charset support.