[fpc-devel] Why: "Can't take the address of constant expressions" here?

Sven Barth pascaldragon at googlemail.com
Fri Jan 13 07:16:34 CET 2023


Am 13.01.2023 um 01:05 schrieb Bart via fpc-devel:
>> The issue is indeed the conversion from UnicodeString to WideString
>> which is not allowed for a var/out parameter. That the compiler doesn't
>> use the error “Call by var for arg no. 3 has to match exactly: Got
>> "UnicodeString" expected "WideString"” is due to Ansi2WideMoveProc()
>> being a function pointer. The code that determines that error is not
>> called in that case, instead the other is caused essentially as a last
>> resort.
> Thanks for explaining.
>
>> You can report a bug with the following sample to hopefully improve this:
>>
> Reported as issue #40106

Thank you.

Regards,
Sven


More information about the fpc-devel mailing list