This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/23287] [3.4/4.0/4.1 regression] Explicitly invoking destructor of template class
- From: "bangerth at dealii dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 8 Aug 2005 17:59:36 -0000
- Subject: [Bug c++/23287] [3.4/4.0/4.1 regression] Explicitly invoking destructor of template class
- References: <20050808174907.23287.eric.tenorio@gmail.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From bangerth at dealii dot org 2005-08-08 17:59 -------
Confirmed, a regression from before the new parser went in.
Smaller testcase:
---------------------------
template <class T> struct A {};
template <class T> void f() {
(new A<T>)->~A();
}
---------------------------
g/x> /home/bangerth/bin/gcc-3.3*/bin/c++ -c x.cc
g/x> /home/bangerth/bin/gcc-3.4*/bin/c++ -c x.cc
x.cc: In function `void f()':
x.cc:4: error: expected class-name before '(' token
g/x> /home/bangerth/bin/gcc-4.0*/bin/c++ -c x.cc
x.cc: In function ‘void f()’:
x.cc:4: error: expected class-name before ‘(’ token
g/x> /home/bangerth/bin/gcc-4.1*/bin/c++ -c x.cc
x.cc: In function ‘void f()’:
x.cc:4: error: expected class-name before ‘(’ token
W.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Keywords| |rejects-valid
Known to fail| |3.4.3 4.0.0 4.1.0
Known to work| |3.3.4
Last reconfirmed|0000-00-00 00:00:00 |2005-08-08 17:59:36
date| |
Summary|Explicitly invoking |[3.4/4.0/4.1 regression]
|destructor of template class|Explicitly invoking
| |destructor of template class
Target Milestone|--- |3.4.5
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23287