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++/50084] New: ICE: C++0x, decltype + remove_reference + new


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

             Bug #: 50084
           Summary: ICE: C++0x, decltype + remove_reference + new
    Classification: Unclassified
           Product: gcc
           Version: 4.6.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: gcc-ice@safetymail.info


ICE while compiling the code below.

Version:
$ g++ -v
Using built-in specs.
COLLECT_GCC=/*/bin/g++
COLLECT_LTO_WRAPPER=/*/libexec/gcc/x86_64-unknown-linux-gnu/4.6.1/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: ./configure --prefix=/*
Thread model: posix
gcc version 4.6.1 (GCC) 


Command line: g++ -std=c++0x -c ice.ii

ice.ii:
//////////////////      8<          //////////////////////////
template<typename>   struct remove_reference;
template<typename T> struct remove_reference<T&> { typedef T type; };

template<typename T> struct A { A(){} };

void f()
{
        struct {
                A<int> a_;
        } * v = 0;

        typedef remove_reference<decltype(*v)>::type at;
        new at();
}
//////////////////      8<        /////////////////////////


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