| 1 |
// { dg-do link } |
| 2 |
// { dg-additional-sources " linkage1-main.cc" } |
| 3 |
|
| 4 |
// Copyright 2002 Free Software Foundation |
| 5 |
|
| 6 |
// Derived by Alexandre Oliva <[email protected]> from code posted by |
| 7 |
// Mark Mitchell <[email protected]> |
| 8 |
|
| 9 |
// Verify that a member of a class is given global linkage when it's a |
| 10 |
// member of a function whose name is taken from a typedef, by |
| 11 |
// checking that another translation unit can call it. We don't do |
| 12 |
// the right things on functions, but we do on data members. |
| 13 |
|
| 14 |
typedef struct { |
| 15 |
void f(); |
| 16 |
} S; |
| 17 |
|
| 18 |
void S::f() {} |