diff options
| author | bors <bors@rust-lang.org> | 2018-05-07 12:30:55 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2018-05-07 12:30:55 +0000 |
| commit | 62889702c9868682a3112a19c75321508d9eb6e6 (patch) | |
| tree | 53e852b1e191e001a0c32f9c883583496187dc51 /src/liballoc/string.rs | |
| parent | c88992d00169f15d8ff9edac8901245b4d21e1c1 (diff) | |
| parent | 9f8f366eeabee6273abf3628bb75ecd3b4b57f22 (diff) | |
| download | rust-62889702c9868682a3112a19c75321508d9eb6e6.tar.gz rust-62889702c9868682a3112a19c75321508d9eb6e6.zip | |
Auto merge of #50487 - nikic:heap-manually-drop, r=Gankro
Use ManuallyDrop instead of Option in BinaryHeap Hole implementation The Option is always Some until drop, where it becomes None. Make this more explicit and avoid unwraps by using ManuallyDrop. This change should be performance-neutral as LLVM already optimizes the unwraps away in the inlined code. However I've seen this pattern copied from here to other crates where it is not optimized away, so I think it would be good to change it.
Diffstat (limited to 'src/liballoc/string.rs')
0 files changed, 0 insertions, 0 deletions
