rust/library/alloc/src
Matthias Krüger 448d2a8417
Rollup merge of #112628 - gootorov:box_alloc_partialeq, r=joshtriplett
Allow comparing `Box`es with different allocators

Currently, comparing `Box`es over different allocators is not allowed:
```Rust
error[E0308]: mismatched types
  --> library/alloc/tests/boxed.rs:22:20
   |
22 |     assert_eq!(b1, b2);
   |                    ^^ expected `Box<{integer}, ConstAllocator>`, found `Box<{integer}, AnotherAllocator>`
   |
   = note: expected struct `Box<{integer}, ConstAllocator>`
              found struct `Box<{integer}, AnotherAllocator>`

For more information about this error, try `rustc --explain E0308`.
error: could not compile `alloc` (test "collectionstests") due to previous error
```
This PR lifts this limitation
2023-06-27 22:10:13 +02:00
..
alloc run alloc benchmarks in Miri and fix UB 2022-11-07 10:34:04 +01:00
boxed More IS_ZST in library 2023-04-21 16:29:27 -07:00
collections s/drain_filter/extract_if/ for Vec, Btree{Map,Set} and LinkedList 2023-06-14 09:28:54 +02:00
ffi Remove a couple of #[doc(hidden)] pub fn and their #[feature] gates 2023-02-10 08:06:35 +01:00
raw_vec Add a unit test for zero-sized types in RawVec. 2021-11-26 19:30:45 +11:00
rc Introduce alloc::::UniqueRc 2023-06-19 12:24:06 -07:00
slice ignore core, alloc and test tests that require unwinding on panic=abort 2023-06-13 15:53:24 +02:00
sync Add Arc::into_inner for safely discarding Arcs without calling the destructor on the inner type. 2023-01-22 01:43:25 +09:00
testing Share testing utilities with non-btree test cases 2022-05-02 10:07:50 +02:00
vec Rollup merge of #112677 - the8472:remove-unusued-field, r=JohnTitor 2023-06-26 23:16:16 +09:00
alloc.rs remove box_free and replace with drop impl 2023-06-16 13:41:06 -07:00
borrow.rs enable rust_2018_idioms for doctests 2023-05-07 00:12:29 +03:00
boxed.rs Rollup merge of #112628 - gootorov:box_alloc_partialeq, r=joshtriplett 2023-06-27 22:10:13 +02:00
fmt.rs enable rust_2018_idioms for doctests 2023-05-07 00:12:29 +03:00
lib.rs reorder attributes to make miri-test-libstd work again 2023-06-11 22:15:46 +02:00
macros.rs Remove or justify use of #[rustc_box] 2023-02-27 20:54:55 -05:00
raw_vec.rs remove some unneeded imports 2023-04-12 19:27:18 +02:00
rc.rs Auto merge of #106450 - albertlarsan68:fix-arc-ptr-eq, r=Amanieu 2023-06-21 05:13:39 +00:00
slice.rs slice: Add a specialization for clone_into when T is Copy 2023-01-28 20:37:01 +01:00
str.rs Spelling library/ 2023-04-26 02:10:22 -04:00
string.rs Rollup merge of #109814 - est31:stabilize_string_leak, r=Amanieu 2023-06-14 18:10:28 +02:00
sync.rs Auto merge of #106450 - albertlarsan68:fix-arc-ptr-eq, r=Amanieu 2023-06-21 05:13:39 +00:00
task.rs Updating Wake example to use new 'pin!' macro 2023-04-25 13:50:50 +02:00
tests.rs fix an alloc test 2023-03-03 17:47:48 +00:00