www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Invalid UTF-8 String with international characters

reply orgoton <orgoton mindless.com> writes:
On my .d files I usually make comments on my own language, and occasionally use
special characters such as "é", "ç" and "ã".

When I try to compiler, DMD complains that those characters are not valid UTF-8
characters. When this error appears on "writefln" strings, it's understandable
(however stupid, because I use them with C), but it also complains if they are
in commented lines! Did I activate some weird option?

I use DMD 1.007 and Code::Blocks Nightly build.

(I have attached my file. Put in some of those characters above and watch the
compiler output).
Mar 08 2007
parent Derek Parnell <derek psych.ward> writes:
On Thu, 08 Mar 2007 10:42:53 -0500, orgoton wrote:

 On my .d files I usually make comments on my own language, and occasionally
use special characters such as "é", "ç" and "ã".
 
 When I try to compiler, DMD complains that those characters are not valid
UTF-8 characters. When this error appears on "writefln" strings, it's
understandable (however stupid, because I use them with C), but it also
complains if they are in commented lines! Did I activate some weird option?
 
 I use DMD 1.007 and Code::Blocks Nightly build.
 
 (I have attached my file. Put in some of those characters above and watch the
compiler output).
Are you using an editor that saves files in UTF format? The DMD compiler only understands text files in UTF and not extended ASCII. -- Derek Parnell Melbourne, Australia "Justice for David Hicks!" skype: derek.j.parnell
Mar 08 2007