]> git.lizzy.rs Git - rust.git/blobdiff - src/libstd/sys/cloudabi/stdio.rs
Refactor stderr_prints_nothing into a more modular function
[rust.git] / src / libstd / sys / cloudabi / stdio.rs
index 9519a926471085f92e64217c60a6bb21c5b977e9..c90dbd8beab869ea1cab1ebea50dc511c3a440a6 100644 (file)
@@ -77,3 +77,7 @@ pub fn is_ebadf(err: &io::Error) -> bool {
 }
 
 pub const STDIN_BUF_SIZE: usize = ::sys_common::io::DEFAULT_BUF_SIZE;
+
+pub fn panic_output() -> Option<impl io::Write> {
+    Stderr::new().ok()
+}