rust/tests/ui/error-codes/E0161.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

21 lines
339 B
Rust
Raw Normal View History

// Check that E0161 is a hard error in all possible configurations that might
// affect it.
2022-04-01 12:13:25 -05:00
// revisions: base ul
//[base] check-fail
//[ul] check-pass
2021-11-20 06:13:40 -06:00
#![allow(incomplete_features)]
2022-04-01 12:13:25 -05:00
#![cfg_attr(ul, feature(unsized_locals))]
2016-05-27 15:06:24 -05:00
trait Bar {
fn f(self);
}
fn foo(x: Box<dyn Bar>) {
x.f();
2022-04-01 12:13:25 -05:00
//[base]~^ ERROR E0161
2016-05-27 15:06:24 -05:00
}
fn main() {}