aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/cpp2a/lambda-targ2a.C
blob: 7136ce7987206915bef01b99f582dce9d9e650ab (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// PR c++/114393
// { dg-do compile { target c++20 } }

template <auto _DescriptorFn> struct c1 {};

template <class _Descriptor, auto F = [] { return _Descriptor(); }>
inline constexpr auto b_v = F;

template <class T, class U>
inline constexpr auto c_v = b_v<U>;

auto f = c_v<int, char>;
using type = decltype(f());
using type = char;