Skip to content

Conversation

@tbu-
Copy link
Contributor

@tbu- tbu- commented Aug 8, 2014

This is implemented using a new struct PartialVec which implements the proper
drop semantics in case the conversion is interrupted by an unwind.

For the old pull request, see #15302.

tbu- added 4 commits August 8, 2014 22:49
This is implemented using a new struct `PartialVec` which implements the proper
drop semantics in case the conversion is interrupted by an unwind.
This specifically includes:
- Fix of the tests
- Remove `transmute` between `Vec`s of different types
This is important because the underlying allocator of the `Vec` passes that
information to the deallocator which needs the guarantee that it is the same
parameters that were also passed to the allocation function.
@tbu-
Copy link
Contributor Author

tbu- commented Aug 8, 2014

The transmute of the Vecs has been removed (which relied on details of the unspecified struct layout), the min_align_of of the two types T and U is now checked.

@alexcrichton
Copy link
Member

Closing due to inactivity (21 days inactive)

bors added a commit that referenced this pull request Sep 15, 2014
This is implemented using a new struct PartialVec which implements the proper
drop semantics in case the conversion is interrupted by an unwind.

For the old pull requests, see #15302, #16369.
bors added a commit to rust-lang-ci/rust that referenced this pull request Jan 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants