[Lazarus] UTF8String and UTF8Delete

Sven Barth pascaldragon at googlemail.com
Thu Dec 10 19:59:26 CET 2015


Am 10.12.2015 19:53 schrieb "Juha Manninen" <juha.manninen62 at gmail.com>:
>
> On Thu, Dec 10, 2015 at 8:18 PM, Ondrej Pokorny <lazarus at kluug.net> wrote:
> > IMO, there should be overloaded versions for UTF8* functions that
> > explicitely accept UTF8String.
> > Or am I wrong?
>
> You are right. I did not even think so far yet.
> A typecast can be used as a workaround now.
> UTF8String and AnsiString have the same memory layout so it should work.

This has nothing to do with the memory layout. Both Utf8String and
AnsiString are AnsiString types and an assignment to each other or a
typecast will result in a codepage conversion if necessary.

Regards,
Sven
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20151210/642aee88/attachment-0003.html>


More information about the Lazarus mailing list