[fpc-devel] Copy() and ZeroBaseStrings

Marco van de Voort fpc at pascalprogramming.org
Mon Apr 7 12:54:17 CEST 2025


Op 7-4-2025 om 08:13 schreef Martin Frb via fpc-devel:
> On 07/04/2025 08:01, Sven Barth via fpc-devel wrote:
>>
>> Also it would be best to simply document as UTF8Copy working 1-based 
>> because you can't detect from the callee-side whether it had been 
>> enabled on the caller-side (especially if they're from different units).
>>
>
> Just an idea.
>
> Maybe having 2 underlying string types for 0 and 1 based. Then it 
> would be possible to use overload.

It is a delphi compatibility feature, to recycle mobile oriented code 
built with earlier Delphi versions. Afaik they later downplayed, so I'm 
not sure if there is new code written for this convention. (I don't do 
mobile development with Delphi, so I'm not sure)

IMHO it is a feature better forgotten.




More information about the fpc-devel mailing list