2019-12-11 08:51:28 -06:00
|
|
|
#![feature(never_type)]
|
2018-10-08 15:08:01 -05:00
|
|
|
#![deny(unused_must_use)]
|
|
|
|
|
|
|
|
#[must_use]
|
|
|
|
fn foo() {}
|
|
|
|
|
|
|
|
#[must_use]
|
|
|
|
fn bar() -> ! {
|
|
|
|
unimplemented!()
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
foo(); //~ unused return value of `foo`
|
|
|
|
|
|
|
|
bar(); //~ unused return value of `bar`
|
|
|
|
}
|