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++/30722] New: ICE on invalid template code #2


This has been derived from test case in PR 30721 but because it ICEs at
different place I report it as different bug.

---------8<--------------

template <typename Numeric>
struct Table
{
  typedef struct
  {
    const char * const name;
  } Tableitem;

  static const Tableitem entries[];
};

enum funky { feeling };

template<funky>
const Table<funky>::Tableitem Table<funky>::entries[] = { {""} };

---------8<--------------

Error:

logout::wilx:~/tmp> g++42 -o ice ice.cxx
ice.cxx:14: internal compiler error: in import_export_decl, at cp/decl2.c:1956
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.

GCC:

logout::wilx:~/tmp> g++42 -v
Using built-in specs.
Target: i386-portbld-freebsd6.2
Configured with: ./..//gcc-4.2-20070117/configure --disable-nls
--with-system-zlib --with-libiconv-prefix=/usr/local --with-gmp=/usr/local
--program-suffix=42 --libdir=/usr/local/lib/gcc-4.2.0
--with-gxx-include-dir=/usr/local/lib/gcc-4.2.0/include/c++/
--infodir=/usr/local/info/gcc42 --disable-rpath --prefix=/usr/local
i386-portbld-freebsd6.2
Thread model: posix
gcc version 4.2.0 20070117 (prerelease)


-- 
           Summary: ICE on invalid template code #2
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: v dot haisman at sh dot cvut dot cz
 GCC build triplet: i386-portbld-freebsd6.2
  GCC host triplet: i386-portbld-freebsd6.2
GCC target triplet: i386-portbld-freebsd6.2


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


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