🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c++
Article #2679

Re: Exceptions in derived class destructors

#2679
From: Dick Menninger
Date: Tue, 21 Nov 1995 02:59
28 lines
1967 bytes
> ==========Steve Clamage, 11/18/95==========
> 
> Apart from all of that, it is unlikely to be a good idea to throw
> an exception from a destructor. It would be safer and less likely
> to leave the program in an unknown state to use some other error-
> reporting method for destructors.

In some cases, it would seem that not allowing exceptions
to be thrown from destructors would be problematic rather
than helpful.  To leave destructors as a "blind spot" for detecting
and reporting exceptions seems to be a very bad idea.
I do not see why destructors are seen as poor stepchildren
relative to all other contexts.  This view will make for a basic
inconsistency in the language.  The rules must be more uniform
or they will make a mess of it.  You have to continue to
destruct pieces in reverse order.  Throwing an exception
in a destructor is merely a special return from that piece of
destruction analogous to the constructor case.

To the contrare.

Good Day
Dick
Dick.Menninger@DaytonOH.ATTGIS.COM
---
[ comp.std.c++ is moderated.  Submission address: std-c++@ncar.ucar.edu.
  Contact address: std-c++-request@ncar.ucar.edu.  The moderation policy
  is summarized in http://dogbert.lbl.gov/~matt/std-c++/policy.html. ]
Technical Details
Message-ID: <DID3FH.12F@falcon.daytonoh.attgis.com>
Path: arc1-ca.pugleaf.net!in2.uu.net!bounce-back
References: <48m6b8$2ll@engnews1.eng.sun.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!in2.uu.net!bounce-back
Date: 21 Nov 95 02:59:36 GMT
Approved: fjh@cs.mu.oz.au
Newsgroups: comp.std.c++
From: Dick Menninger <Dick.Menninger@daytonoh.attgis.com>
Subject: Re: Exceptions in derived class destructors
Message-ID: <DID3FH.12F@falcon.daytonoh.attgis.com>
Reply-To: mennid <Dick.Menninger@daytonoh.attgis.com>
Organization: AT&T Global Information Solutions
X-Newsreader: DiscussIT 2.5.1.3 for MS Windows [AT&T Software Products Division]
References: <48m6b8$2ll@engnews1.eng.sun.com>
X-Original-Date: Mon, 20 Nov 1995 21:52:28 GMT
X-Auth: PGPMoose V1.1 PGP comp.std.c++
 iQBFAgUBMLFAr+EDnX0m9pzZAQGTVAF/ZPkUwjWA4PJSvE+gQ23+JrgPh/+tx7NL
 x1wGiD9JGdd+mz21CT3f4ziTPirtDads
 =2VzH