For declaring a trait and implementing it for only a single type at the same time, as commonly done in the “extension trait” pattern, you can reduce the boilerplate slightly by using a macro. E. g. this crate provides one: extension_trait in extension_trait - Rust
In your example where it's merely different modules, note that inherent impl StructA blocks will still work as long as it's the same crate; but maybe you were simply using models as a stand-in for crates in your example code.