diff options
| author | Felix S. Klock II <pnkfelix@pnkfx.org> | 2015-01-27 18:12:34 +0100 |
|---|---|---|
| committer | Felix S. Klock II <pnkfelix@pnkfx.org> | 2015-01-27 18:12:34 +0100 |
| commit | 326443105b897171424c6efde15198cd7a25bc61 (patch) | |
| tree | 47b3d1eeace292b32b0a9fa31d02e0c2bce9e5a1 /src/libstd/sys/windows/stack_overflow.rs | |
| parent | e365e4c05454d94131d14d0207c12bb895a4c186 (diff) | |
| download | rust-326443105b897171424c6efde15198cd7a25bc61.tar.gz rust-326443105b897171424c6efde15198cd7a25bc61.zip | |
trans: When coercing to `Box<Trait>` or `Box<[T]>`, leave datum in its original L-/R-value state.
This fixes a subtle issue where temporaries were being allocated (but not necessarily initialized) to the (parent) terminating scope of a match expression; in particular, the code to zero out the temporary emitted by `datum.store_to` is only attached to the particular match-arm for that temporary, but when going down other arms of the match expression, the temporary may falsely appear to have been initialized, depending on what the stack held at that location, and thus may have its destructor erroneously run at the end of the terminating scope. Test cases to appear in a follow-up commit. Fix #20055
Diffstat (limited to 'src/libstd/sys/windows/stack_overflow.rs')
0 files changed, 0 insertions, 0 deletions
