[fpc-pascal] methods of an object to create others objects

Marcos Douglas md at delfire.net
Wed Jul 7 16:42:57 CEST 2010


On Wed, Jul 7, 2010 at 10:44 AM, Andrew Brunner
<andrew.t.brunner at gmail.com> wrote:
>
> Grame, no more caveats.  If Unmount had memory that needed to be
> released then the same methodology stands.  Disk1.Unmount was placed
> there to prove a point.  That w/o handling Obj2.Free would never be
> called in context (the outstanding proposed example).
>
> As far as *HUGE* problem.  Having to restart my server would be huge..
> Especially in high scale, high available production environments.
> Having a handle in place that says CATCH STUFF HERE like Save to SQL
> server (if your needing to write to disk).  The example I introduced
> is a good one.  Ignoring the exception will indeed cause a fatal
> error.  Handling the exception is the best practice here.

Nobody said handling exceptions is bad practice!
I understand that there are cases that have nothing to do when an
exception (unexpectedly) is generated. We can not foresee everything.


MD.



More information about the fpc-pascal mailing list