]> git.lizzy.rs Git - rust.git/blobdiff - tests/ui/debug_assert_with_mut_call.rs
Auto merge of #68717 - petrochenkov:stabexpat, r=varkor
[rust.git] / tests / ui / debug_assert_with_mut_call.rs
index a588547b943a4b20b3cc86bcd18e3c2e18c08d25..477a47118d4116587fc6526ca01f3f72edf639e2 100644 (file)
@@ -1,6 +1,8 @@
+// compile-flags: --edition=2018
 #![feature(custom_inner_attributes)]
 #![rustfmt::skip]
-#![allow(clippy::trivially_copy_pass_by_ref, clippy::cognitive_complexity, clippy::redundant_closure_call)]
+#![warn(clippy::debug_assert_with_mut_call)]
+#![allow(clippy::redundant_closure_call)]
 
 struct S;
 
@@ -114,6 +116,12 @@ fn misc() {
     })());
 }
 
+async fn debug_await() {
+    debug_assert!(async {
+        true
+    }.await);
+}
+
 fn main() {
     func_non_mutable();
     func_mutable();
@@ -121,4 +129,5 @@ fn main() {
     method_mutable();
 
     misc();
+    debug_await();
 }