Add an UNSPEC_PROLOGUE_USE to prevent the link register from being considered dead.
[official-gcc.git] / gcc / testsuite / g++.old-deja / g++.law / scope4.C
blob1cfb54e9c34a1be10e0810b820ef2e46e2e6767b
1 // Build don't link: 
2 // GROUPS passed scoping
3 // local-class file
4 // From: daniels@sugar.neosoft.com (Brad Daniels)
5 // Date:     Thu, 5 Aug 93 15:36:36 CDT
6 // Subject:  Bug in g++ 2.4.5: Can't touch nested class identifier inside its members
7 // Message-ID: <9308051536.AA06115@NeoSoft.Com>
9 void f() {
10     class foo {
11         int x;
12     public:
13         foo() : x(1) {}
14         int bar() { foo p; return p.x; }
15     };