Skip to content
Myr

Add ui test for writing anyhow instead of bail

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Currently fails: Expected test case to fail to compile, but it succeeded.

authored by David Tolnay · committed by David Tolnay · parent 3ca5036 · Browse files · 1 file+11 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+11 added−0 removed

  • tests:+11 added−0 removed

1 file+11 added−0 removed

added:tests/ui/must-use.rs+11 added
1#![deny(unused_must_use)]23use anyhow::anyhow;45fn main() -> anyhow::Result<()> {6 if true {7 // meant to write bail!8 anyhow!("it failed");9 }10 Ok(())11}