[fpc-devel] Encoded AnsiString
DrDiettrich1 at aol.com
Sun Dec 29 17:53:38 CET 2013
Michael Van Canneyt schrieb:
> On Sun, 29 Dec 2013, Hans-Peter Diettrich wrote:
>>> This will be combined with the dotted unit filenames, to be Delphi
>>> 2010+ compatible.
>> How do I create source files for use with both versions?
> What do you mean by this statement ?
I'm not familiar with dotted unit names, they seem not to be used in XE.
So I only can imagine something like conditionals around the different
items in un/dotted environment, to keep "Classes" separate from
Are directories involved? If so, does the Delphi structure match the FPC
>> Where can I jump in?
> When I'm done I will release a version for testing to the public.
>> How can a user request an string of a specific allocation size?
> You should not.
>> Another one:
>> I've heard that a mix of encodings converts the (concatenated) output
>> (RawByteString?) to CP_ACP, with possible losses. Is this correct?
> Define "output" ?
s := SomeACPstr+SomeUTF8str+"äöü";
In XE I can concatenate ACP and UTF-8 strings and assign it to an OEM
string without losses. Somebody said this will fail in FPC, on e.g.
due to an (intermediate?) conversion of myPath+allfiles to CP_ACP.
Of course the string must be converted to CP_ACP if FindFirst expects
exactly an AnsiString(0) argument, otherwise something is broken.
More information about the fpc-devel