Skip to content

Commit e63457a

Browse files
authored
Fix comment on Ord for SourceId (#15103)
### What does this PR try to resolve? In PR #14980, the Ord impl for SourceId was changed, but the comment wasn’t updated. So it is now incorrect. This PR updates the comment to match the implementation. ### How should we test and review this PR? Read the Ord for SourceId code and make sure the updated comment describes what it does. ### Additional information None
2 parents cecde95 + 6e46d4c commit e63457a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/cargo/core/source_id.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -581,8 +581,8 @@ impl PartialOrd for SourceId {
581581
}
582582
}
583583

584-
// Custom comparison defined as canonical URL equality for git sources and URL
585-
// equality for other sources, ignoring the `precise` and `name` fields.
584+
// Custom comparison defined as source kind and canonical URL equality,
585+
// ignoring the `precise` and `name` fields.
586586
impl Ord for SourceId {
587587
fn cmp(&self, other: &SourceId) -> Ordering {
588588
// If our interior pointers are to the exact same `SourceIdInner` then

0 commit comments

Comments
 (0)