[fpc-devel] utf8 in 2.6.0

Jonas Maebe jonas.maebe at elis.ugent.be
Tue Jan 1 16:06:21 CET 2013


On 01 Jan 2013, at 15:40, Martin wrote:

> ok, leaves me with my original problem.
> 
> On said ppc, using the original file (no codepage directive). file should be identical (svn checkout) (yet on 2nd thought I can't be sure, that it wasn't open in an editor and saved with utf8 bom...).
> 
> So on that ppc something goes wrong. From the feedback I had, it looks exactly as if the encoding of the constant was changed.  So what I was looking for was a way to 100% prevent that. Something that tells the compiler: Whatever encoding you find or expect or whatever encoding the output should be, do not touch strings. just take them byte by byte.
> Does that exist?

As mentioned in my previous reply: if you don't use the codepage directive, then the compiler won't change anything. If you assign the string constant to a unicodestring or pass it as such a parameter, it will of course still be converted from ansi to utf-16 at run time.


Jonas


More information about the fpc-devel mailing list