[DUG] basic question
Dennis Chuah
dennis_cs_chuah at hotmail.com
Thu Jul 26 23:58:38 NZST 2007
No, a constuctor will not return Nil. If an exception is raised in a
constructor, the implicit finalisation code is called (which then calls the
Destructor), and the exception bubbles up to the next exception handler.
----- Original Message -----
From: "Jeremy North" <jeremy.north at gmail.com>
To: "NZ Borland Developers Group - Delphi List" <delphi at delphi.org.nz>
Sent: Thursday, July 26, 2007 7:09 PM
Subject: Re: [DUG] basic question
> Which means any constructor could return NIL. Which you didn't make
> clear in your explanation. I just wanted to clear that up for others
> incase they weren't aware of this.
>
> On 7/26/07, Dennis Chuah <dennis_cs_chuah at hotmail.com> wrote:
>>
>> A constructor ALWAYS creates an instance, even if it encounters an
>> exception. The implicit exception handling code then finalises the
>> instance.
> _______________________________________________
> NZ Borland Developers Group - Delphi mailing list
> Post: delphi at delphi.org.nz
> Admin: http://delphi.org.nz/mailman/listinfo/delphi
> Unsubscribe: send an email to delphi-request at delphi.org.nz with Subject:
> unsubscribe
>
More information about the Delphi
mailing list