You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
http crate does not compile against latest nightly (caused by TryFrom). #49436
I replied to @sfackler in the issue linked above, but I thought it would be worth posting here:
My understanding was that these sorts of "expected breakage" would go through an ecosystem "crater" (or whatever it is called) and if it broke things it wouldn't be applied.
I understand the problem that one must be able to add new fns / traits, but if breaking the http crate is considered "expected breakage", that seems to fail at Rust's promise for backwards compatibility as this will cascade down do everyone that depends on http as well as production Rust users.
The "fix" seems to be to not include TryFrom in std's prelude until the next Rust edition, which is coming soon.
The "fix" seems to be to not include TryFrom in std's prelude until the next Rust edition, which is coming soon.
It does seem like adding new traits to the prelude with a generic name like that should be reserved for new editions.
I'd suggest that the real solution is to have the compiler resolve the conflict by ranking explicit trait imports as higher than traits in a prelude (I guess any glob import).
Reacted by Eliza Weisman, Carl Lerche, Max Gortman, Jaro Fietz and Leonardo Schwarz
Activity
carllerche commentedon Mar 28, 2018
I replied to @sfackler in the issue linked above, but I thought it would be worth posting here:
My understanding was that these sorts of "expected breakage" would go through an ecosystem "crater" (or whatever it is called) and if it broke things it wouldn't be applied.
I understand the problem that one must be able to add new fns / traits, but if breaking the
httpcrate is considered "expected breakage", that seems to fail at Rust's promise for backwards compatibility as this will cascade down do everyone that depends onhttpas well as production Rust users.The "fix" seems to be to not include
TryFrominstd's prelude until the next Rust edition, which is coming soon.seanmonstar commentedon Mar 28, 2018
It does seem like adding new traits to the prelude with a generic name like that should be reserved for new editions.
I'd suggest that the real solution is to have the compiler resolve the conflict by ranking explicit trait imports as higher than traits in a prelude (I guess any glob import).
udoprog commentedon Mar 29, 2018
There's a fair bit of discussion going on on this topic in the stabilization PR.
Mark-Simulacrum commentedon May 29, 2018
Since we've reverted TryFrom stabilization entirely and I believe this is no longer a problem, I'm going to close this.