gcc/testsuite/g++.dg/ext/dllimport11.C
raw| 1 | // PR target/23589 |
| 2 | // Template member functions do not get dllimport status of class. |
| 3 | // { dg-do compile { target i?86-*-cygwin* i?86-*-mingw* x86_64-*-mingw* } } |
| 4 | |
| 5 | struct __attribute__((dllimport)) Foo |
| 6 | { |
| 7 | template <class T> Foo (T); |
| 8 | }; |
| 9 | |
| 10 | void a (int i) |
| 11 | { |
| 12 | Foo f(i); |
| 13 | } |
| 14 | |
| 15 | template <class T> Foo::Foo (T) {} // no dllimport warnings on definition. |