reference icon indicating copy to clipboard operation
reference copied to clipboard

Clarify wording of orphan rule to avoid ambiguity

Open MrOnijohn opened this issue 2 months ago • 0 comments

https://doc.rust-lang.org/reference/items/implementations.html#orphan-rules

"The orphan rule states that a trait implementation is only allowed if either the trait or at least one of the types in the implementation is defined in the current crate."

To me (non native English speaker, Rust learner) this sentence is ambiguous, in that "is defined" could be taken to mean both "is being defined" and "is already defined elsewhere than", which have opposite meanings.

I suggest this small change (in italics): "The orphan rule states that a trait implementation is only allowed if either the trait or at least one of the types in the implementation is originally declared in the current crate."

MrOnijohn avatar Sep 16 '25 15:09 MrOnijohn