diff --git a/src/test/ui/async-await/issue-70818.rs b/src/test/ui/async-await/issue-70818.rs new file mode 100644 index 000000000000..b914c9b17abd --- /dev/null +++ b/src/test/ui/async-await/issue-70818.rs @@ -0,0 +1,5 @@ +// edition 2018 + +fn d(t: T) -> impl std::future::Future + Send { //~ Error `T` cannot be sent between threads safely + async { t } +}