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++.old-deja/] [g++.other/] [goto4.C] - Blame information for rev 338

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 305 jeremybenn
// { dg-do run  }
2
// Test that we clean up temporaries bound to references properly when
3
// jumping out of their scope.
4
 
5
int ret = 1;
6
 
7
struct A
8
{
9
  ~A() { ret = 0; }
10
};
11
 
12
void f()
13
{
14
  if (0)
15
    {
16
    out:
17
      return;
18
    }
19
  const A& a = A();
20
  goto out;
21
}
22
 
23
int main()
24
{
25
  f();
26
  return ret;
27
}

powered by: WebSVN 2.1.0

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