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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [torture/] [pr42890.C] - Blame information for rev 701

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 693 jeremybenn
// PR tree-optimization/42890
2
// { dg-do compile }
3
 
4
extern "C" int puts (const char *) throw ();
5
 
6
struct S
7
{
8
  const char *a;
9
  const char **b;
10
  S (const char *s) { a = s; b = &a; }
11
  ~S () { puts (a); }
12
};
13
 
14
void
15
foo (int (*fn) (const char *))
16
{
17
  S a ("foo");
18
  fn ("bar");
19
}
20
 
21
int
22
main ()
23
{
24
  foo (puts);
25
}

powered by: WebSVN 2.1.0

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