| > In that specific case, the inherent impl is preferred, so there’s no ambiguity. That is even worse. It means your code can silently start doing the wrong thing rather than erroring, if the inherent impl does something different from the trait. > And yes, there are tons of things that can subtly break code. This isn't some obscure bug in some deep edge case though, it's a completely normal and common way of using the language (implementing your own traits on foreign types) predictably leading to breakage in an obvious way. I am not sure why it should be called "subtle". Anyway, given this issue, I think the meme that Rust is backwards-compatible is really oversold. It'd be more honest to frame it as "we hope releases are backwards-compatible, but we like adding new functions to the stdlib, so no promises" rather than marketing BC as a major selling point as is done now. > In practice, the experience that the vast majority of users report to us is that they do not experience breakage when upgrading the compiler. It's anecdotal for sure, but I'm personally aware of times when the exact situation I'm describing has happened and caused headaches for people. |