Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upAdd ManuallyDrop::take #55421
Conversation
rust-highfive
assigned
kennytm
Oct 27, 2018
This comment has been minimized.
This comment has been minimized.
|
r? @kennytm (rust_highfive has picked a reviewer for you, use r? to override) |
rust-highfive
added
the
S-waiting-on-review
label
Oct 27, 2018
kennytm
added
the
T-libs
label
Oct 27, 2018
This comment has been minimized.
This comment has been minimized.
|
Tracking issue currently points to this PR, that will need to be updated if this is accepted to be merged. cc @scottmcm |
This comment has been minimized.
This comment has been minimized.
|
The job Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
kennytm
reviewed
Oct 27, 2018
src/libcore/mem.rs Outdated
src/libcore/mem.rs Outdated
src/libcore/mem.rs Outdated
src/libcore/mem.rs Outdated
src/libcore/mem.rs Outdated
This comment has been minimized.
This comment has been minimized.
|
The job Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
This comment has been minimized.
This comment has been minimized.
|
Thanks for the ccs, but I don't have anything to add |
This comment has been minimized.
This comment has been minimized.
|
r=me after squashing everything down to 1 commit. cc @rust-lang/libs and @rust-lang/wg-unsafe-code-guidelines in case there's any problems caused by this function. |
CAD97
force-pushed the
CAD97:patch-1
branch
from
6929770
to
0757c0f
Oct 28, 2018
This comment has been minimized.
This comment has been minimized.
|
Squashed. |
This comment has been minimized.
This comment has been minimized.
|
@bors r+ rollup |
This comment has been minimized.
This comment has been minimized.
|
|
bors
added
S-waiting-on-bors
and removed
S-waiting-on-review
labels
Oct 28, 2018
kennytm
added a commit
to kennytm/rust
that referenced
this pull request
Oct 28, 2018
bors
added a commit
that referenced
this pull request
Oct 28, 2018
This comment has been minimized.
This comment has been minimized.
|
I expected the definition to be |
bors
merged commit 0757c0f
into
rust-lang:master
Oct 28, 2018
1 check passed
CAD97
deleted the
CAD97:patch-1
branch
Oct 29, 2018
This comment has been minimized.
This comment has been minimized.
|
@SimonSapin I think it ended up this way because the code snippit on IRLO that became this was written as an external function. The alternative implementation sounds good too. |
CAD97 commentedOct 27, 2018
•
edited
Tracking issue: #55422
Proposed in this form in https://internals.rust-lang.org/t/mini-rfc-manuallydrop-take/8679,
see that thread for some history.
A small convenience wrapper for
ManuallyDropthat makes a pattern (taking ownership of the contained data in drop) more obvious.