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++/29535] New: [4.1/4.2 Regression] ICE in instantiate_class_template, at cp/pt.c:5728


For the following testcase

typedef long unsigned int size_t;
typedef int int16_t __attribute__ ((__mode__ (__HI__)));
typedef int int32_t __attribute__ ((__mode__ (__SI__)));
typedef unsigned char uint8_t;
typedef unsigned short int uint16_t;
template <class FIRST, class SECOND> class Ident { };
template <class TYPE> class Less { };
template <class NUM, int DIM, class TOL> class Pixel { };
typedef Pixel<uint8_t,1,int32_t> PixelY;
template <class INDEX, class SIZE> class Region2D {
public:
  class Extent  { };
};
template <class TYPE, size_t SIZES> class Allocator {
  class Chunk  { };
};
template <class KEY, class VALUE, class KEYFN, class PRED> class SkipList {
  struct Node  { };
  enum { HEADERCHUNK = 10 };
public:
  typedef Allocator<Node,HEADERCHUNK> Allocator;
  class Iterator;
  class ConstIterator  { };
  struct InsertResult  { };
};
template <class TYPE, class PRED = Less<TYPE> > class Set {
  typedef SkipList<TYPE,TYPE,Ident<TYPE,TYPE>,PRED> Imp;
  Imp m_oImp;
public:
  typedef typename Imp::Allocator Allocator;
  Set (const PRED &a_rPred = PRED(),    
       Allocator &a_rAlloc = Imp::sm_oNodeAllocator) 
    : m_oImp (a_rPred, a_rAlloc) { }
  typedef typename Imp::Iterator Iterator;
  typedef typename Imp::ConstIterator ConstIterator;
  Iterator Begin (void) {}
};
template <class INDEX, class SIZE> class SetRegion2D {
  typedef Region2D<INDEX,SIZE> BaseClass;
  typedef typename BaseClass::Extent Extent;
  typedef Set<Extent> Extents;
public:
  typedef typename Extents::ConstIterator ConstIterator;
  ConstIterator Begin (void) const { }
  class FloodFillControl;
};
template <class INDEX, class SIZE>
class SetRegion2D<INDEX,SIZE>::FloodFillControl {
  bool ShouldUseExtent (Extent &a_rExtent) { }
};
template <class PIXEL_TOL, class PIXELINDEX,  class FRAMESIZE, PIXELINDEX PGW >
class MotionSearcher {
  typedef SetRegion2D<PIXELINDEX,FRAMESIZE> Region_t;
  class MatchThrottleFloodFillControl {
    typedef typename Region_t::FloodFillControl BaseClass;
    MatchThrottleFloodFillControl (typename BaseClass::Allocator
&a_rAllocator);
  };
  MatchThrottleFloodFillControl m_oMatchThrottleFloodFillControl;
};
class MotionSearcherY : public MotionSearcher<int32_t, int16_t, int32_t, 4> {};


-- 
           Summary: [4.1/4.2 Regression] ICE in instantiate_class_template,
                    at cp/pt.c:5728
           Product: gcc
           Version: 4.1.2
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: rguenth at gcc dot gnu dot org


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


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