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++/47488] [4.4,4.5,4.6 Regression] (sizeof|decltype) + template + string literals: ICE in write_template_arg_literal, at cp/mangle.c


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

Jonathan Wakely <redi at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |ice-on-valid-code
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2011.01.27 10:56:51
            Summary|[C++0x] decltype + template |[4.4,4.5,4.6 Regression]
                   |+ string literals: ICE in   |(sizeof|decltype) +
                   |write_template_arg_literal, |template + string literals:
                   |at cp/mangle.c              |ICE in
                   |                            |write_template_arg_literal,
                   |                            |at cp/mangle.c
     Ever Confirmed|0                           |1

--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> 2011-01-27 10:56:52 UTC ---
This c++98 variation using sizeof instead of decltype gives an ICE in the same
place:

template < typename T >
int f( const T &, const char * );

template<int> struct N { };

template < typename T >
N<sizeof( f( T(), "" ) )> g( const T &t );

void h()
{
    g( 0 );
}


This is a regression since 4.1 which doesn't ICE:

testcase.cpp: In function 'void h()':
testcase.cpp:11: sorry, unimplemented: call_expr cannot be mangled due to a
defect in the C++ ABI


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