Files
aji/tests/conformance/source/scopes/moved_spawn.aji
T

11 lines
290 B
Rust

// expect: reject E7005
// phase: 6
// spec: docs/spec/15-source-language.md §7
module scope_cases.moved_spawn
fn work() -> u64 effects [] { 42u64 }
fn main() -> u64 effects [task.spawn, task.wait] {
scope s { let t = task.spawn(move s, work); let n = task.join(move t); }
0u64
}