Advertisement
cwchen

[Rust] Writing to standard error

Aug 26th, 2017
742
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Rust 0.14 KB | None | 0 0
  1. use std::io::Write;
  2.  
  3. fn main() {
  4.     writeln!(&mut std::io::stderr(), "Error message")
  5.         .expect("Failed to print to stderr");
  6. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement