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++/29979] New: ICE with vector types in templates


The following code snippet triggers an ICE since GCC 3.3:

===================================================
template<typename T> struct A
{
  static const T i = 1;
  int __attribute__((vector_size(8))) a[i];
};
===================================================

bug.cc:4: internal compiler error: in fold_convert, at fold-const.c:2066
Please submit a full bug report, [etc.]


A similar code snippet triggers a segfault:

===================================================
template<typename T> struct A
{
  int __attribute__((vector_size(8))) a[T::i];
};
===================================================

bug.cc:3: internal compiler error: Segmentation fault
Please submit a full bug report, [etc.]


-- 
           Summary: ICE with vector types in templates
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code, monitored
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: reichelt at gcc dot gnu dot org


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


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