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

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.2.2/] [gcc/] [testsuite/] [g++.dg/] [lookup/] [decl1.C] - Diff between revs 149 and 154

Go to most recent revision | Only display areas with differences | Details | Blame | View Log

Rev 149 Rev 154
// { dg-do compile }
// { dg-do compile }
// Copyright (C) 2002 Free Software Foundation, Inc.
// Copyright (C) 2002 Free Software Foundation, Inc.
// Contributed by Nathan Sidwell 24 Dec 2002 
// Contributed by Nathan Sidwell 24 Dec 2002 
// PR 8702. Failure to match templates.
// PR 8702. Failure to match templates.
template  struct C1{};
template  struct C1{};
template 
template 
struct C2 {
struct C2 {
  template operator C1();
  template operator C1();
  template operator C2();
  template operator C2();
};
};
template template
template template
C2::operator C1()
C2::operator C1()
{
{
  return C1();
  return C1();
}
}
struct A
struct A
{
{
  operator int ();                      // { dg-error "operator" "" }
  operator int ();                      // { dg-error "operator" "" }
  operator float ();                    // { dg-error "operator" "" }
  operator float ();                    // { dg-error "operator" "" }
  operator float () const;              // { dg-error "operator" "" }
  operator float () const;              // { dg-error "operator" "" }
  template  operator T * (); // { dg-error "candidates" "" }
  template  operator T * (); // { dg-error "candidates" "" }
};
};
A::operator short () { // { dg-error "prototype for" "" }
A::operator short () { // { dg-error "prototype for" "" }
  return 0;
  return 0;
}
}
 
 

powered by: WebSVN 2.1.0

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