Mercurial > hg > CbC > CbC_gcc
comparison gcc/testsuite/g++.dg/cpp2a/fn-template10.C @ 145:1830386684a0
gcc-9.2.0
author | anatofuz |
---|---|
date | Thu, 13 Feb 2020 11:34:05 +0900 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
131:84e7813d76e9 | 145:1830386684a0 |
---|---|
1 // P0846R0 | |
2 // { dg-do compile } | |
3 // { dg-options "-std=c++2a" } | |
4 | |
5 int h; | |
6 void g(); | |
7 void e(); | |
8 void e(int); | |
9 void e(int, int); | |
10 | |
11 namespace N { | |
12 struct A { }; | |
13 template <class T> static int f(T) { return 1; } | |
14 template <class T> static int g(T) { return 2; } | |
15 template <class T> static int h(T); | |
16 template <class T> static int e(T) { return 3; } | |
17 } | |
18 | |
19 int v = e<N::A>(N::A()); | |
20 int x = f<N::A>(N::A()); | |
21 int y = g<N::A>(N::A()); | |
22 int z = h<N::A>(N::A()); // { dg-error "expected" } |