about summary refs log tree commit diff
path: root/src/test/ui/async-await/unused-lifetime.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/async-await/unused-lifetime.rs')
-rw-r--r--src/test/ui/async-await/unused-lifetime.rs39
1 files changed, 0 insertions, 39 deletions
diff --git a/src/test/ui/async-await/unused-lifetime.rs b/src/test/ui/async-await/unused-lifetime.rs
deleted file mode 100644
index 6cfd36ba9e8..00000000000
--- a/src/test/ui/async-await/unused-lifetime.rs
+++ /dev/null
@@ -1,39 +0,0 @@
-// Check "unused_lifetimes" lint on both async and sync functions
-// Both cases should be diagnosed the same way.
-
-// edition:2018
-
-#![deny(unused_lifetimes)]
-
-async fn async_wrong_without_args<'a>() {} //~ ERROR lifetime parameter `'a` never used
-
-async fn async_wrong_1_lifetime<'a>(_: &i32) {} //~ ERROR lifetime parameter `'a` never used
-
-async fn async_wrong_2_lifetimes<'a, 'b>(_: &'a i32, _: &i32) {} //~ ERROR lifetime parameter `'b` never used
-
-async fn async_right_1_lifetime<'a>(_: &'a i32) {}
-
-async fn async_right_2_lifetimes<'a, 'b>(_: &'a i32, _: &'b i32) {}
-
-async fn async_right_trait_bound_lifetime<'a, I>(_: I)
-where
-    I: Iterator<Item = &'a i32>
-{}
-
-fn wrong_without_args<'a>() {} //~ ERROR lifetime parameter `'a` never used
-
-fn wrong_1_lifetime<'a>(_: &i32) {} //~ ERROR lifetime parameter `'a` never used
-
-fn wrong_2_lifetimes<'a, 'b>(_: &'a i32, _: &i32) {} //~ ERROR lifetime parameter `'b` never used
-
-fn right_1_lifetime<'a>(_: &'a i32) {}
-
-fn right_2_lifetimes<'a, 'b>(_: &'a i32, _: &'b i32) {}
-
-fn right_trait_bound_lifetime<'a, I>(_: I)
-where
-    I: Iterator<Item = &'a i32>
-{}
-
-
-fn main() {}