rust/tests/ui/box/unit/unique-object-move.rs

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

19 lines
340 B
Rust
Raw Normal View History

// run-pass
#![allow(dead_code)]
// Issue #5192
// pretty-expanded FIXME #23616
2015-02-18 23:58:07 +00:00
pub trait EventLoop { fn foo(&self) {} }
pub struct UvEventLoop {
uvio: isize
}
impl EventLoop for UvEventLoop { }
pub fn main() {
let loop_: Box<dyn EventLoop> = Box::new(UvEventLoop { uvio: 0 }) as Box<dyn EventLoop>;
2013-08-17 15:37:42 +00:00
let _loop2_ = loop_;
}