C++ PATCH: check throw validity
Wed Jun 30 23:15:00 GMT 1999
Robert Lipe wrote:
> the compiler, that's OK with me. I just couldn't add the //ERRORs while
> the tools were ICE-ing.
Not entirely, some of the problems were due to irrelevant -ansi -pedantic
moaning, (which are the default test compiler flags).
eh990323-1.C failed to compile due to calling `void g(void)' as
`g(A<char*>())'. Once `void g(int)' is substituted, the test passes. (the test
is about template temporary cleanups).
ice990323-1.C - yes, it now correctly errors
ice990323-2.C - would not compile as main was defined `main()' not `int
main()'. Once changed it passes.
ice990323-3.C - now correctly errors, it needed /ERROR marks
ice990323-4.C - ditto
ice990323-5.C - ditto
> > 2) we didn't enforce 15.1/3 (thou shall not throw an incomplete type ...) and
> > died horribly. This patch fixes build_throw to do so.
> That sounds like the root of some of the ICEs, right?
> > I can't find wording disallowing throwing (T *)NULL, and believe it > valid.
> Since the contributor is an ISO C++ committee member that delights in
> tormenting EH, it probably is. :-)
Dr Nathan Sidwell :: Computer Science Department :: Bristol University
I have seen the death of PhotoShop -- it is called GIMP
firstname.lastname@example.org http://www.cs.bris.ac.uk/~nathan/ email@example.com
More information about the Gcc-patches