[Lazarus] Unicode branch

Flávio Etrusco flavio.etrusco at gmail.com
Sun Jun 30 19:11:19 CEST 2013


On Sat, Jun 29, 2013 at 4:43 PM, Marcos Douglas <md at delfire.net> wrote:
> On Fri, Jun 28, 2013 at 1:07 PM, Hans-Peter Diettrich
> <DrDiettrich1 at aol.com> wrote:
>> Graeme Geldenhuys schrieb:
>>
>>> On 2013-06-27 21:32, Hans-Peter Diettrich wrote:
>>>>
>>>> I don't see how this is related to managed objects.
>>>
>>>
>>> If FPC implements managed objects, is it going to behave _exactly_ like
>>> Delphi, or slightly different to Delphi - like what happened to the
>>> Interfaces implementation.
>>
>>
>> Right, and you seem to be the only one playing around with manual
>> refcounting, and having (consequential) problems with managed objects.
>
> Everybody that have used Interfaces in Delphi had already problems at
> least once.
> It seems easiest to use "CORBA interfaces" instead "COM interfaces"
> because you have more control on your objects.
>
> Marcos Douglas


That's a bold statement. COM interfaces work nice and simple as long
don't try to use the implicit reference-count mechanism to hack
"aspects" and other stuff, and when you use TInterfacedObject avoid
using using it as a normal object (unless you know what you're doing).
Not to repeat myself, but I only wish there was a way
TInterfacedObject (and probably a few others) replaced the
default constructor to return IUnknown... Even shadowing the default
constructor with a factory (class method that casts the constructor to
IUnknown, declare another protected-creatively-named-constructor)
would be an improvement IMHO.

-Flávio




More information about the Lazarus mailing list