OpenCores
URL https://opencores.org/ocsvn/scarts/scarts/trunk

Subversion Repositories scarts

[/] [scarts/] [trunk/] [toolchain/] [scarts-gcc/] [gcc-4.1.1/] [gcc/] [testsuite/] [g++.dg/] [template/] [ttp7.C] - Rev 12

Compare with Previous | Blame | View Log

// { dg-do compile }
// Contributed by Andrew Pinski <pinskia at gcc dot gnu dot org>
// PR c++/13810: ICE while parsing invalid default argument for a 
//   template template parameter.

struct X;
template<int> struct A {};   

template<template<int> class = X > struct B1 {};     // { dg-error "as a default value" }
template<template<int> class = A<0> > struct B2 {};  // { dg-error "as a default value" }

template <typename T>
struct S {
  template <template <typename> class = S>   struct I1 {};  // { dg-error "as a default value" }
  template <template <typename> class = ::S> struct I2 {};
};

Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.