This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/32081] New: Conflicting exception specifications not rejected in template specialization
- From: "andrew dot stubbs at st dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 25 May 2007 09:52:50 -0000
- Subject: [Bug c++/32081] New: Conflicting exception specifications not rejected in template specialization
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
The following C++ code should not compile:
template <class T>
void foo(T) throw (int);
template<>
void
foo (short) throw (short)
{
}
The change in exception specification, the throw, is not been detected. A
simple example without templates is rejected correctly.
The C++ standard discusses this in clause 15.4/2.
--
Summary: Conflicting exception specifications not rejected in
template specialization
Product: gcc
Version: 4.1.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: andrew dot stubbs at st dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32081