aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/cpp2a/lambda-generic2.C
blob: 6116639f871abd2fdf256e10e06466cb76cb9378 (plain)
1
2
3
4
5
6
7
// P0428R2
// { dg-do compile }

int j = []<class T>(T t, int i) { return i; }(3, 4);
// { dg-error "lambda templates are only available with" "" { target c++17_down } .-1 }
// { dg-error "lambda expressions only available with" "" { target c++98_only } .-2 }
// { dg-error "invalid use of 'auto'" "" { target c++98_only } .-3 }