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

Subversion Repositories openrisc

[/] [openrisc/] [tags/] [gnu-src/] [gcc-4.5.1/] [gcc-4.5.1-or32-1.0rc1/] [gcc/] [testsuite/] [g++.dg/] [template/] [friend18.C] - Diff between revs 301 and 338

Only display areas with differences | Details | Blame | View Log

Rev 301 Rev 338
// { dg-do run }
// { dg-do run }
// Copyright (C) 2003 Free Software Foundation, Inc.
// Copyright (C) 2003 Free Software Foundation, Inc.
// Contributed by Nathan Sidwell 26 Mar 2003 
// Contributed by Nathan Sidwell 26 Mar 2003 
// PR 10158. implicit inline template friends ICE'd
// PR 10158. implicit inline template friends ICE'd
template  struct X
template  struct X
{
{
  template  friend int foo(X const &)
  template  friend int foo(X const &)
  {
  {
    return N * 10000 + M;
    return N * 10000 + M;
  }
  }
};
};
X<1234> bring;
X<1234> bring;
int main() {
int main() {
  return foo<5678> (bring) != 12345678;
  return foo<5678> (bring) != 12345678;
}
}
 
 

powered by: WebSVN 2.1.0

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