This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/23287] [3.4/4.0/4.1 regression] Explicitly invoking destructor of template class


------- 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 &#8216;void f()&#8217;: 
x.cc:4: error: expected class-name before &#8216;(&#8217; token 
 
g/x> /home/bangerth/bin/gcc-4.1*/bin/c++ -c x.cc 
x.cc: In function &#8216;void f()&#8217;: 
x.cc:4: error: expected class-name before &#8216;(&#8217; 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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]