rust/tests/ui/coroutine/issue-57478.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

17 lines
228 B
Rust
Raw Normal View History

2023-05-07 18:38:52 +00:00
// check-pass
2023-10-19 21:46:28 +00:00
#![feature(negative_impls, coroutines)]
2021-10-08 22:09:20 +00:00
struct Foo;
impl !Send for Foo {}
fn main() {
assert_send(|| {
let guard = Foo;
drop(guard);
yield;
})
}
fn assert_send<T: Send>(_: T) {}