]>
git.proxmox.com Git - rustc.git/blob - src/tools/clippy/tests/ui-toml/await_holding_invalid_type/await_holding_invalid_type.rs
1 #![warn(clippy::await_holding_invalid_type)]
2 use std
::net
::Ipv4Addr
;
4 async
fn bad() -> u32 {
5 let _x
= String
::from("hello");
9 async
fn bad_reason() -> u32 {
10 let _x
= Ipv4Addr
::new(127, 0, 0, 1);
14 async
fn good() -> u32 {
16 let _x
= String
::from("hi!");
17 let _y
= Ipv4Addr
::new(127, 0, 0, 1);
20 let _x
= String
::from("hi!");
24 async
fn baz() -> u32 {
28 #[allow(clippy::manual_async_fn)]
29 fn block_bad() -> impl std
::future
::Future
<Output
= u32> {
31 let _x
= String
::from("hi!");