1 // Test that discarded statements differ from unevaluated operands in some
2 // ways.
3 // { dg-do compile { target c++17 } }
4 
5 struct A { int i; };
6 
main()7 int main()
8 {
9   if constexpr(true)
10     ;
11   else
12     {
13       []{}();
14       A::i;			// { dg-error "non-static" }
15     }
16 }
17