diff options
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.pt/explicit35.C')
-rw-r--r-- | gcc/testsuite/g++.old-deja/g++.pt/explicit35.C | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.pt/explicit35.C b/gcc/testsuite/g++.old-deja/g++.pt/explicit35.C new file mode 100644 index 000000000..f174e8f9d --- /dev/null +++ b/gcc/testsuite/g++.old-deja/g++.pt/explicit35.C @@ -0,0 +1,17 @@ +// { dg-do link } +// { dg-options "-ansi -pedantic-errors -w" } +// GROUPS passed templates +struct S +{ + template <class T> + void foo(T t); +}; + +template <> +void S::foo<int>(int i) { } + +int main() +{ + S s; + s.foo<int>(3.0); +} |