Files
rust/tests/ui/offload/offload_negative_device.rs
2026-08-19 22:29:00 +03:00

13 lines
390 B
Rust

//@ compile-flags: -Zunstable-options -Zoffload=Test -Clto=fat --emit=llvm-ir -Zdeduplicate-diagnostics=yes
//@ no-prefer-dynamic
//@ needs-offload
#![feature(gpu_offload)]
fn kernel() {}
fn main() {
core::offload::offload! { kernel = kernel, args = (), device = -1 }
//~^ ERROR evaluation panicked: offload device must be non-negative; omit `device` to use the default device
}