1 // Issue #66530: We would ICE if someone compiled with `-o /dev/null`, 2 // because we would try to generate auxiliary files in `/dev/` (which 3 // at least the OS X file system rejects). 4 // 5 // An attempt to `-o` into a directory we cannot write into should indeed 6 // be an error; but not an ICE. 7 // 8 // However, some folks run tests as root, which can write `/dev/` and end 9 // up clobbering `/dev/null`. Instead we'll use a non-existent path, which 10 // also used to ICE, but even root can't magically write there. 11 12 // compile-flags: -o /does-not-exist/output 13 14 // The error-pattern check occurs *before* normalization, and the error patterns 15 // are wildly different between build environments. So this is a cop-out (and we 16 // rely on the checking of the normalized stderr output as our actual 17 // "verification" of the diagnostic). 18 19 // error-pattern: error 20 21 // On Mac OS X, we get an error like the below 22 // normalize-stderr-test "failed to write bytecode to /does-not-exist/output.non_ice_error_on_worker_io_fail.*" -> "io error modifying /does-not-exist/" 23 24 // On Linux, we get an error like the below 25 // normalize-stderr-test "couldn't create a temp dir.*" -> "io error modifying /does-not-exist/" 26 27 // ignore-windows - this is a unix-specific test 28 // ignore-emscripten - the file-system issues do not replicate here 29 // ignore-wasm - the file-system issues do not replicate here 30 // ignore-arm - the file-system issues do not replicate here, at least on armhf-gnu 31 32 #![crate_type="lib"] 33 34 #![cfg_attr(not(feature = "std"), no_std)] 35 pub mod task { 36 pub mod __internal { 37 use crate::task::Waker; 38 } 39 pub use core::task::Waker; 40 } 41