Summary on Re: [fpc-pascal] Unicode file routines proposal

Felipe Monteiro de Carvalho felipemonteiro.carvalho at gmail.com
Tue Jul 1 14:51:35 CEST 2008


On Tue, Jul 1, 2008 at 9:30 AM, Marco van de Voort <marcov at stack.nl> wrote:
> My is having both an UTF8string and a UTF16string, on all platforms that support
> unicode. So I don't get this remark.

Unless I understood your proposal wrong it involves a TMarcoString
which will be declared like this:

{$ifdef Linux}
  If SystemEncoding = utf-8 then TMarcoString = Utf8String
  else TMarcoString = ansistring;
{$endif}
{$ifdef Windows}
  If WindowsNT then TMarcoString = utf16string
  else TMarcoString = ansistring;
{$endif}
{$ifdef Darwin}
  TMarcoString = utf8string;
{$endif}

Just how do you implement a string routine with TMarcoString? Fill it
with ifdefs?

> It is just that on unix, the fileroutines will be defined as utf8string

So you are going to convert in non utf8 unix?

-- 
Felipe Monteiro de Carvalho



More information about the fpc-pascal mailing list