This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug java/11755] non-ASCII characters treated as errors even in comments if LANG=C
- From: "tromey at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 1 Aug 2003 01:06:20 -0000
- Subject: [Bug java/11755] non-ASCII characters treated as errors even in comments if LANG=C
- References: <20030801003642.11755.bero@arklinux.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11755
------- Additional Comments From tromey at gcc dot gnu dot org 2003-08-01 01:06 -------
gcj uses iconv() on platforms where it is available.
gcj also tries to use the locale's encoding by default.
On Linux, in the C locale, you are using ASCII.
glibc's iconv() is strict in this situation and will
reject non-ASCII characters.
The fix is to use something like "gcj --encoding=ISO-8859-1".
You don't see this with javac since Sun uses their own
encoding converters, and their ASCII converter isn't
strict about bytes whose high bit is set.