1*b65b1f32SSaar Raz // RUN:  %clang_cc1 -std=c++2a -fconcepts-ts -verify %s
2*b65b1f32SSaar Raz 
3*b65b1f32SSaar Raz auto l1 = [] (auto x) requires (sizeof(decltype(x)) == 1) { return x; };
4*b65b1f32SSaar Raz // expected-note@-1{{candidate template ignored: constraints not satisfied [with $0 = int]}}
5*b65b1f32SSaar Raz // expected-note@-2{{because 'sizeof(decltype(x)) == 1' (4 == 1) evaluated to false}}
6*b65b1f32SSaar Raz 
7*b65b1f32SSaar Raz auto l1t1 = l1('a');
8*b65b1f32SSaar Raz auto l1t2 = l1(1);
9*b65b1f32SSaar Raz // expected-error@-1{{no matching function for call to object of type '(lambda at}}
10*b65b1f32SSaar Raz 
11*b65b1f32SSaar Raz auto l2 = [] (auto... x) requires ((sizeof(decltype(x)) >= 2) && ...) { return (x + ...); };
12*b65b1f32SSaar Raz // expected-note@-1{{candidate template ignored: constraints not satisfied [with $0 = <char>]}}
13*b65b1f32SSaar Raz // expected-note@-2{{candidate template ignored: constraints not satisfied [with $0 = <int, char>]}}
14*b65b1f32SSaar Raz // expected-note@-3 2{{because 'sizeof(decltype(x)) >= 2' (1 >= 2) evaluated to false}}
15*b65b1f32SSaar Raz 
16*b65b1f32SSaar Raz auto l2t1 = l2('a');
17*b65b1f32SSaar Raz // expected-error@-1{{no matching function for call to object of type '(lambda at}}
18*b65b1f32SSaar Raz auto l2t2 = l2(1, 'a');
19*b65b1f32SSaar Raz // expected-error@-1{{no matching function for call to object of type '(lambda at}}
20*b65b1f32SSaar Raz auto l2t3 = l2((short)1, (short)1);