| 1 |
// PR c++/109790 |
| 2 |
// This used to work until GCC 10; force the usage of ABI 15 (the highest |
| 3 |
// usable in GCC 10) and check that the mangling (actually wrong; see |
| 4 |
// lambda-ice3a.C) matches that of GCC 10's default ABI version (14). |
| 5 |
|
| 6 |
// { dg-do compile { target c++14 } } |
| 7 |
// { dg-additional-options "-fabi-version=15" } |
| 8 |
|
| 9 |
auto ll = [](auto ... ){}; |
| 10 |
template <class _Impl, class _Args> |
| 11 |
void mm(void (_Impl::*__p)(_Args) const); |
| 12 |
template <class _Ts> |
| 13 |
using __impl_for = decltype(mm(&decltype(ll)::operator()<_Ts>)); |
| 14 |
template <class _Ts> __impl_for<_Ts> f() { } |
| 15 |
void aaa() { |
| 16 |
f<int>(); |
| 17 |
} |
| 18 |
|
| 19 |
// { dg-final { scan-assembler "_Z1fIiEDTcl2mmadsrN2llMUlDpT_E_EclIT_EEEv" } } |