diff options
| author | Ralf Jung <post@ralfj.de> | 2018-08-03 18:02:34 +0200 |
|---|---|---|
| committer | Ralf Jung <post@ralfj.de> | 2018-08-03 18:09:20 +0200 |
| commit | b3d2346230736b253d8f2a9df461901b7de67abd (patch) | |
| tree | 99d3cec56d67d886fd59a5a6370258d796137181 /src/libcore/tests | |
| parent | 88e0ff14a81a2122222e32cf7c285f585c516cfd (diff) | |
| download | rust-b3d2346230736b253d8f2a9df461901b7de67abd.tar.gz rust-b3d2346230736b253d8f2a9df461901b7de67abd.zip | |
unsized ManuallyDrop
Diffstat (limited to 'src/libcore/tests')
| -rw-r--r-- | src/libcore/tests/manually_drop.rs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/libcore/tests/manually_drop.rs b/src/libcore/tests/manually_drop.rs index 96bc9247da6..b8826ad4087 100644 --- a/src/libcore/tests/manually_drop.rs +++ b/src/libcore/tests/manually_drop.rs @@ -21,4 +21,8 @@ fn smoke() { let x = ManuallyDrop::new(TypeWithDrop); drop(x); + + // also test unsizing + let x : Box<ManuallyDrop<[TypeWithDrop]>> = Box::new(ManuallyDrop::new([TypeWithDrop])); + drop(x); } |
