I'm aware of the fact that this can't be changed now, because Box<T>
is a [fundamental]
type. This thread covered that topic already: Why `Box<T>` does not implement `PartialEq<Box<U>>` where `T: PartialEq<U>`? - libs - Rust Internals
But I'm curious, could that have been implemented, prior to v1.0.0 stabilization? Arrays and slices work that way. But the actual impls don't explain why slices implement this and box does not .
alice
March 5, 2021, 2:19pm
2
I don't see any reason it couldn't.
Looks like I found the answer to my question: https://github.com/rust-lang/rust/issues/20063
Namely, there's issues with ambiguous types in many cases, eg Option<T>
: https://github.com/rust-lang/rust/issues/20063#issuecomment-105251291
system
Closed
June 17, 2021, 4:22am
4
This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.