Files
rust/src/liballoc
bors aa4e57ca8f Auto merge of #65091 - sekineh:into-iter-sorted, r=KodrAus
Implement ordered/sorted iterators on BinaryHeap as per #59278

I've implemented the ordered version of iterator on BinaryHeap as per #59278.

# Added methods:

* `.into_iter_sorted()`
  * like `.into_iter()`; but returns elements in heap order
* `.drain_sorted()`
  * like `.drain()`; but returns elements in heap order
  * It's a bit _lazy_; elements are removed on drop. (Edit: it’s similar to vec::Drain)

For `DrainSorted` struct, I implemented `Drop` trait following @scottmcm 's [suggestion](https://github.com/rust-lang/rust/issues/59278#issuecomment-537306925)

# ~TODO~ DONE
* ~I think I need to add more tests other than doctest.~

# **Notes:**
* we renamed `_ordered` to `_sorted`, because the latter is more common in rust libs. (as suggested by @KodrAus )
2019-10-31 15:15:53 +00:00
..
2019-08-04 14:50:26 +02:00
2019-10-25 19:55:58 +09:00
2019-09-25 08:42:46 -04:00
2019-08-04 14:50:26 +02:00
2019-10-17 23:02:09 +02:00
2019-10-22 19:56:41 -04:00
2019-09-07 22:40:57 +03:00
2019-09-16 16:45:16 +02:00
2019-10-19 13:47:32 +02:00
2019-10-25 11:25:52 -04:00