2021-03-14 20:11:37 +01:00
|
|
|
// revisions: mir thir
|
|
|
|
// [thir]compile-flags: -Z thir-unsafeck
|
|
|
|
|
2018-12-16 22:21:47 -05:00
|
|
|
struct X(());
|
|
|
|
impl X {
|
2013-09-02 23:30:00 +10:00
|
|
|
pub unsafe fn with(&self) { }
|
2012-12-06 16:13:40 -08:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
2018-12-16 22:21:47 -05:00
|
|
|
X(()).with(); //~ ERROR requires unsafe function or block
|
2012-12-06 16:13:40 -08:00
|
|
|
}
|