[Bug c++/33965] New: internal compiler error: tree check: expected class 'type', have 'constant' (integer_cst) in cp_type_quals, at cp/typeck.c:6955 (vararg templates)

eric dot niebler at gmail dot com gcc-bugzilla@gcc.gnu.org
Wed Oct 31 21:36:00 GMT 2007


In the following SFINAE scenario involving vararg templates an non-type
template parameters, the compiler ICEs instead of ignoring the specialization.

Latest SVN g++ with patches from Doug Gregor for vararg templates.

template<typename T>
struct foo
{
    static bool const value = false;
};

template<template<typename...> class T, typename... Args>
struct foo<T<Args...> >
{
    static bool const value = false;
};

template<int I>
struct int_
{};

int main()
{
    foo<int_<0> > f; // ICE
}


-- 
           Summary: internal compiler error: tree check: expected class
                    'type', have 'constant' (integer_cst) in cp_type_quals,
                    at cp/typeck.c:6955 (vararg templates)
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: eric dot niebler at gmail dot com


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



More information about the Gcc-bugs mailing list