public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/60081] New: Internal compiler error: Error reporting routines re-entered.
@ 2014-02-05 16:04 stanislav.manilov at gmail dot com
  2014-03-06 20:35 ` [Bug c++/60081] " dartmetrash at gmail dot com
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: stanislav.manilov at gmail dot com @ 2014-02-05 16:04 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 60081
           Summary: Internal compiler error: Error reporting routines
                    re-entered.
           Product: gcc
           Version: 4.7.3
            Status: UNCONFIRMED
          Severity: major
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: stanislav.manilov at gmail dot com

Created attachment 32054
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=32054&action=edit
preprocessed source

It appears that declaring a class member to have type a vector of unique_ptr's
is the reason for this bug, but could not verify details.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug c++/60081] Internal compiler error: Error reporting routines re-entered.
  2014-02-05 16:04 [Bug c++/60081] New: Internal compiler error: Error reporting routines re-entered stanislav.manilov at gmail dot com
@ 2014-03-06 20:35 ` dartmetrash at gmail dot com
  2014-03-06 20:37 ` dartmetrash at gmail dot com
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: dartmetrash at gmail dot com @ 2014-03-06 20:35 UTC (permalink / raw)
  To: gcc-bugs

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

lmat <dartmetrash at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dartmetrash at gmail dot com

--- Comment #1 from lmat <dartmetrash at gmail dot com> ---
I found this internal error, too, and found this Bug (60081) as a "possible
duplicate" of the one I was creating. I think it may be a duplicate as I
certainly have std::vector<std::unique_ptr<....> >s. I'll change them to
something else and see where I can go from there. Thanks for filing this bug
and beginning a diagnosis, Mr. Manilov!


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug c++/60081] Internal compiler error: Error reporting routines re-entered.
  2014-02-05 16:04 [Bug c++/60081] New: Internal compiler error: Error reporting routines re-entered stanislav.manilov at gmail dot com
  2014-03-06 20:35 ` [Bug c++/60081] " dartmetrash at gmail dot com
@ 2014-03-06 20:37 ` dartmetrash at gmail dot com
  2014-03-06 20:39 ` dartmetrash at gmail dot com
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: dartmetrash at gmail dot com @ 2014-03-06 20:37 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from lmat <dartmetrash at gmail dot com> ---
Right, changed unique_ptr to shared_ptr in my code base and the error goes
away. Have you seen if this bug still appears on a 4.8 build ?


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug c++/60081] Internal compiler error: Error reporting routines re-entered.
  2014-02-05 16:04 [Bug c++/60081] New: Internal compiler error: Error reporting routines re-entered stanislav.manilov at gmail dot com
  2014-03-06 20:35 ` [Bug c++/60081] " dartmetrash at gmail dot com
  2014-03-06 20:37 ` dartmetrash at gmail dot com
@ 2014-03-06 20:39 ` dartmetrash at gmail dot com
  2014-04-30 12:29 ` stanislav.manilov at gmail dot com
  2014-05-11 14:41 ` paolo.carlini at oracle dot com
  4 siblings, 0 replies; 6+ messages in thread
From: dartmetrash at gmail dot com @ 2014-03-06 20:39 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #3 from lmat <dartmetrash at gmail dot com> ---
Created attachment 32292
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=32292&action=edit
Another reproduction

For what it's worth, I just uploaded bugreprt.gz which has more code that
reproduces the issue along with the makefile I used, etc.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug c++/60081] Internal compiler error: Error reporting routines re-entered.
  2014-02-05 16:04 [Bug c++/60081] New: Internal compiler error: Error reporting routines re-entered stanislav.manilov at gmail dot com
                   ` (2 preceding siblings ...)
  2014-03-06 20:39 ` dartmetrash at gmail dot com
@ 2014-04-30 12:29 ` stanislav.manilov at gmail dot com
  2014-05-11 14:41 ` paolo.carlini at oracle dot com
  4 siblings, 0 replies; 6+ messages in thread
From: stanislav.manilov at gmail dot com @ 2014-04-30 12:29 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from Stan Manilov <stanislav.manilov at gmail dot com> ---
Here is a simple way to reproduce the bug:

==============================
#include <vector>
#include <memory>

int main() {
        std::vector<std::unique_ptr<int>> v;
        std::unique_ptr<int> px(new int (1));
        v.push_back(px);
}
==============================

There is a bug in the code: push_back tries to copy the given element by
default. This should return an error along the lines of "Call to deleted copy
constructor of std::unique_ptr". Instead it gives ICE.

A solution to the bug in the code is to explicitly call std::move like so:

==============================
#include <vector>
#include <memory>

int main() {
        std::vector<std::unique_ptr<int>> v;
        std::unique_ptr<int> px(new int (1));
        v.push_back(std::move(px));
}
==============================


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug c++/60081] Internal compiler error: Error reporting routines re-entered.
  2014-02-05 16:04 [Bug c++/60081] New: Internal compiler error: Error reporting routines re-entered stanislav.manilov at gmail dot com
                   ` (3 preceding siblings ...)
  2014-04-30 12:29 ` stanislav.manilov at gmail dot com
@ 2014-05-11 14:41 ` paolo.carlini at oracle dot com
  4 siblings, 0 replies; 6+ messages in thread
From: paolo.carlini at oracle dot com @ 2014-05-11 14:41 UTC (permalink / raw)
  To: gcc-bugs

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

Paolo Carlini <paolo.carlini at oracle dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |FIXED

--- Comment #5 from Paolo Carlini <paolo.carlini at oracle dot com> ---
Fixed a lot of time ago, in 4.8.0.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2014-05-11 14:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-05 16:04 [Bug c++/60081] New: Internal compiler error: Error reporting routines re-entered stanislav.manilov at gmail dot com
2014-03-06 20:35 ` [Bug c++/60081] " dartmetrash at gmail dot com
2014-03-06 20:37 ` dartmetrash at gmail dot com
2014-03-06 20:39 ` dartmetrash at gmail dot com
2014-04-30 12:29 ` stanislav.manilov at gmail dot com
2014-05-11 14:41 ` paolo.carlini at oracle dot com

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).