]> git.lizzy.rs Git - rust.git/blob - src/test/ui/lint/must_use-unit.rs
Auto merge of #66590 - Aaron1011:fix/real-impl-trait-coherence, r=varkor
[rust.git] / src / test / ui / lint / must_use-unit.rs
1 #![deny(unused_must_use)]
2
3 #[must_use]
4 fn foo() {}
5
6 #[must_use]
7 fn bar() -> ! {
8     unimplemented!()
9 }
10
11 fn main() {
12     foo(); //~ unused return value of `foo`
13
14     bar(); //~ unused return value of `bar`
15 }