summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/cpp1z/noexcept-type9.C
blob: 45b64997072b61653e25f2e545b2d26eb8260cd1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// Test for PMF template args.
// { dg-options -std=c++17 }
// { dg-do compile }

struct A
{
  void f() noexcept;
  void g();
};

template <void (A::*)()> struct B { };
template <void (A::*)() noexcept> struct C { };

B<&A::f> b1;
B<&A::g> b2;

C<&A::f> c1;
C<&A::g> c2;			// { dg-error "" }