public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "redi at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/45894] [4.5 Regression] [C++0x] ICE: segmentation fault with -Wall
Date: Wed, 02 Feb 2011 17:08:00 -0000	[thread overview]
Message-ID: <bug-45894-4-9z1p7NNSus@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-45894-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #13 from Jonathan Wakely <redi at gcc dot gnu.org> 2011-02-02 17:08:14 UTC ---
... alternatively, I'll re-open PR 47589 as a separate non-C++0x bug on the 4.4
branch

here's a reduced testcase which makes 4.4.5 ICE, a regression since (at least)
4.1

typedef unsigned long long nsec_t;

class Engine { };

struct Fd
{
    typedef void(*Cb)(Engine*, Fd*, nsec_t);

    Fd(Cb cb);
};


namespace detail {

struct Cb
{
    template<class EventTag, class Derived> static void fd(Engine*, Fd*,
nsec_t);
};

}

template<class EventTag, class Derived>
struct TaggedFd : Fd
{
    TaggedFd()
        : Fd(detail::Cb::fd<EventTag, Derived>)
    {}
};


struct FdTag {};

struct DemuxTestClient
    : TaggedFd<FdTag, DemuxTestClient>
{
    DemuxTestClient() { }
};

$ ~/tools/Linux-x86_64/44/bin/g++ max.cc
max.cc: In constructor 'TaggedFd<EventTag, Derived>::TaggedFd() [with EventTag
= FdTag, Derived = DemuxTestClient]':
max.cc:37:   instantiated from here
max.cc:27: internal compiler error: Segmentation fault


  parent reply	other threads:[~2011-02-02 17:08 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-05 12:47 [Bug c++/45894] New: " gcc at abeckmann dot de
2010-10-05 13:08 ` [Bug c++/45894] [4.5/4.6 Regression] [C++0x] " redi at gcc dot gnu.org
2010-10-05 13:33 ` paolo.carlini at oracle dot com
2010-10-05 13:41 ` redi at gcc dot gnu.org
2010-10-06  2:05 ` hjl.tools at gmail dot com
2010-10-06 10:32 ` rguenth at gcc dot gnu.org
2010-10-26 13:35 ` jakub at gcc dot gnu.org
2010-11-05 12:50 ` jakub at gcc dot gnu.org
2010-11-08 14:28 ` dodji at gcc dot gnu.org
2010-11-08 17:40 ` jakub at gcc dot gnu.org
2010-11-09 11:53 ` jakub at gcc dot gnu.org
2010-11-09 11:56 ` [Bug c++/45894] [4.5 " jakub at gcc dot gnu.org
2010-11-09 11:57 ` jakub at gcc dot gnu.org
2010-11-11 20:42 ` jakub at gcc dot gnu.org
2010-11-11 22:14 ` jakub at gcc dot gnu.org
2011-02-02 16:08 ` redi at gcc dot gnu.org
2011-02-02 16:28 ` redi at gcc dot gnu.org
2011-02-02 17:08 ` redi at gcc dot gnu.org [this message]
2011-02-03 22:35 ` redi at gcc dot gnu.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=bug-45894-4-9z1p7NNSus@http.gcc.gnu.org/bugzilla/ \
    --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).