Have we ever considered allowing orphans in bin crates?

71 points MengerianMango 24 comments

The main reason for not allowing them is that a dep anywhere in your tree could add a trait and break everything, to put it simply. That's a good reason to disallow them in libs, but for bin crates that's not really a concern, and arguably the risk is something we should leave up to the application developer, the end user.

I'd also consider going a step further, since there will be commonly popular orphans. Perhaps they should also be allowed in first order dependencies of bin crates, to prevent people from vendoring/copy-pasting common orphans. The same logic of allowing user discretion applies to first order dependencies to a bin crate. It would be sorta weird to create a sort of bifurcation in the lib crates, but not really a huge issue since most don't need orphans anw.

This is an existing concept, allowing/semi-encouraging dirtiness and laziness in bin/app crates for the sake of productivity. Like how anyhow is bad in libs but ok if you're writing an app.