diff options
Diffstat (limited to '')
-rw-r--r-- | src/test/ui/issues/issue-2708.rs | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/src/test/ui/issues/issue-2708.rs b/src/test/ui/issues/issue-2708.rs new file mode 100644 index 000000000..abd5e9507 --- /dev/null +++ b/src/test/ui/issues/issue-2708.rs @@ -0,0 +1,30 @@ +// run-pass +#![allow(dead_code)] +#![allow(non_snake_case)] + +// pretty-expanded FIXME #23616 + +#![feature(box_syntax)] + +struct Font { + fontbuf: usize, + cairo_font: usize, + font_dtor: usize, + +} + +impl Drop for Font { + fn drop(&mut self) {} +} + +fn Font() -> Font { + Font { + fontbuf: 0, + cairo_font: 0, + font_dtor: 0 + } +} + +pub fn main() { + let _f: Box<_> = box Font(); +} |