repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
PR c++/56973, DR 696 - capture constant variables only as needed.
[official-gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
cpp1y
/
var-templ21.C
blob
a7b089958364c828dc588b29bc7314f5d54a5db4
1
// PR c++/64455
2
// { dg-do compile { target c++14 } }
3
4
template<typename Type>
5
constexpr bool IsType = true;
6
7
template <bool b, class T> struct Test
8
{
9
};
10
11
template <class T>
12
struct Test<true, T>
13
{
14
typedef T type;
15
};
16
17
template<class T>
18
struct X {
19
typedef typename Test<IsType<T>,T>::type type;
20
};
21
22
int main()
23
{
24
X<int>::type t;
25
}