blob: 2449c37fc9930183aa960d97178d96adc49d36c0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
// PR c++/67084
// { dg-do compile { target c++17 } }
// { dg-options "-fconcepts" }
template <class T>
constexpr bool p = false;
template <class T>
constexpr bool p<T*> = false;
template <class T>
requires true
constexpr bool p<T*> = false;
template <class T>
requires true && T() == 0
constexpr bool p<T*> = true;
template <class T>
constexpr bool q = false;
template <class T>
constexpr bool q<T*> = true;
template <class T>
requires false
constexpr bool q<T*> = false;
template <class T>
requires false && T() != 0
constexpr bool q<T*> = false;
static_assert (p<int*>,"");
|