public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "bangerth at dealii dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/12333] Explicit call to MyClass::~MyClass() yields "sorry, unimplemented"
Date: Thu, 18 Sep 2003 23:50:00 -0000	[thread overview]
Message-ID: <20030918222243.31105.qmail@sources.redhat.com> (raw)
In-Reply-To: <20030918185509.12333.John.Bossom@cognos.com>

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12333


bangerth at dealii dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
   Last reconfirmed|0000-00-00 00:00:00         |2003-09-18 22:22:43
               date|                            |


------- Additional Comments From bangerth at dealii dot org  2003-09-18 22:22 -------
Interesting. With this slightly reduced code  
-----------------------------  
struct X {  
    void f() {  
      X::~X();  
    }  
    virtual ~X(){}  
};  
----------------------------------  
we get from present mainline:  
tmp/g> ../build-gcc/gcc-install/bin/c++ -c x.cc  
x.cc: In member function `void X::f()':  
x.cc:3: error: no matching function for call to `X::X()'  
x.cc:5: note: candidates are: virtual X::~X()  
  
Note the message for line 3, which talks about the _con_structor, and that the candidate  
given on line 5 is the _de_structor :-) Alas, the whole message is wrong, the code should  
compile.  
  
With 3.3, we get this:  
tmp/g> ~/bin/gcc-3.3/bin/c++ -c x.cc  
x.cc: In member function `void X::f()':  
x.cc:3: error: 'struct X' has no member named '`type_decl' not supported by  
x.cc:3: sorry, unimplemented: dump_expr  
x.cc:3: sorry, unimplemented: ~<expression error>'  
  
And then, with 3.2:  
tmp/g> /usr/bin/c++ -c x.cc  
x.cc: In member function `void X::f()':  
x.cc:3: cannot call destructor `X::~X' without object  
  
  
While playing around a little more, I also came across an ICE. Since it is a regression 
I opened a new PR for it: PR 12335. 
 
W.


  reply	other threads:[~2003-09-18 22:22 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-09-18 19:27 [Bug c++/12333] New: " John dot Bossom at cognos dot com
2003-09-18 23:50 ` bangerth at dealii dot org [this message]
2003-09-19  2:15 ` [Bug c++/12333] Explicit call to MyClass::~MyClass() not allowed bangerth at dealii dot org
2003-09-19 19:17 ` John dot Bossom at cognos dot com
2003-12-19  2:04 ` pinskia at gcc dot gnu dot org
2004-01-13  3:40 ` [Bug c++/12333] [DR 272] " giovannibajo at libero dot it
2004-01-13 15:33 ` bangerth at dealii dot org
2004-03-29 14:25 ` bangerth at dealii dot org
2005-01-03 20:52 ` pinskia at gcc dot gnu dot org
2005-01-05  5:24 ` austern at apple dot com
2005-06-19 14:27 ` pinskia at gcc dot gnu dot org
2005-09-30 23:41 ` pinskia at gcc dot gnu dot org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030918222243.31105.qmail@sources.redhat.com \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).