================
@@ -282,3 +281,11 @@ static_assert(__is_same_as(int, helper<int>));
 
 
 } // namespace GH138018
+
+namespace GH172814 {
+auto t() {
+  int x = 0;
+  return [](auto w=[&] { x += w(); }); // expected-error {{lambda expression 
in default argument cannot capture any entity}} \
+                                       // expected-error {{expected body of 
lambda expression}}
----------------
a-tarasyuk wrote:

@zyn0217 Thanks for the feedback. If this is acceptable, I also wanted to use a 
case from the reported issue to keep the original case. WDYT?

https://github.com/llvm/llvm-project/pull/173776
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to