gcc/testsuite/g++.dg/cpp0x/deleted10.C
raw| 1 | // PR c++/60753 |
| 2 | // { dg-do compile { target c++11 } } |
| 3 | |
| 4 | template<class T> void foo (T); |
| 5 | |
| 6 | template<> void foo<int> (int); |
| 7 | template<> void foo<int> (int) = delete; // { dg-error "deleted" } |
| 8 | |
| 9 | struct S |
| 10 | { |
| 11 | template<class T> void bar (T); |
| 12 | }; |
| 13 | |
| 14 | template<> void S::bar<int> (int); |
| 15 | template<> void S::bar<int> (int) = delete; // { dg-error "deleted" } |