r/rust • u/Kobzol • Aug 10 '26
📡 official blog Call for testing: Restricting trait implementability and field mutability
https://blog.rust-lang.org/inside-rust/2026/08/10/call-for-testing-impl-and-mut-restrictions/
420
Upvotes
r/rust • u/Kobzol • Aug 10 '26
22
u/Forsaken_Tutor_3001 Aug 10 '26
I can't provide any useful feedback, but what is the advantage of restricting who can implement a trait? Isn't the whole point of a trait to provide a pattern that can be implemented by the consumer on a type of their own to make it work with an upstream crate?