title: Suppress panic output in Rust when using panic::catch_unwind
body: <p>I'm using <a href="https://doc.rust-lang.org/std/panic/fn.catch_unwind.html" rel="noreferrer"><code>panic::catch_unwind</code></a> to catch a panic:</p>
  
  <pre><code>use std::panic;
  
  fn main() {
      let result = panic::catch_unwind(|| {
          panic!("test panic");
      });
  
      match result {
          Ok(res) =&gt; res,
          Err(_) =&gt; println!("caught panic!"),
      }
  }
  </code></pre>
  
  <p>(<a href="https://play.rust-lang.org/?gist=d92d346014ce523136554fe607cfb53d&amp;version=stable" rel="noreferrer">Playground</a>)</p>
  
  <p>This seems to work just fine, but I am still getting the output of the panic to stdout. I'd like this to only print out:</p>
  
  <pre class="lang-none prettyprint-override"><code>caught panic!
  </code></pre>
  
  <p>Instead of </p>
  
  <pre class="lang-none prettyprint-override"><code>thread '&lt;main&gt;' panicked at 'test panic', &lt;anon&gt;:6
  note: Run with `RUST_BACKTRACE=1` for a backtrace.
  caught panic!
  </code></pre>