Warnings for unhandled c++ exceptions?

Wesley W. Terpstra terpstra@ito.tu-darmstadt.de
Mon Feb 3 19:37:00 GMT 2003


On Mon, Feb 03, 2003 at 08:31:12PM +0100, Gabriel Dos Reis wrote:
> "Wesley W. Terpstra" <terpstra@ito.tu-darmstadt.de> writes:
> 
> | There are lots of warnings for behaviours that are *legal* C++ but
> | unethical. 
> 
> These words ("legal", "unethical") sound wrong to me.  Right now
> you're the first person using them in this discussion.  I don't know
> why... 

Because I was reading the C++ FAQ LITE yesterday. :-)
I thought his definitions were apt.
They are strong words though; maybe I should drop them.

What the FAQ meant with them is:
	legal = syntactically correct and valid C++
	        that also won't segfault, break, etc
	unethical = code that is fragile with respect to aging

eg:	if (x = y) { ... } is legal code
but, unethical

I will stop using them; I thought that perhaps their use was more widespread
than that fellows page. Plus -- there are terse and (with the above
definitions) precise.

---
Wes



More information about the Gcc mailing list