-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
A-diagnosticsArea: Messages for errors, warnings, and lintsArea: Messages for errors, warnings, and lintsE-needs-testCall for participation: An issue has been fixed and does not reproduce, but no test has been added.Call for participation: An issue has been fixed and does not reproduce, but no test has been added.
Description
Code:
// #[deriving(Eq, Ord, PartialEq, PartialOrd)]
struct X { x: int }
pub fn main() {
let mut b: Vec<X> = Vec::new();
b.sort();
}
Error:
tmp.rs:6:7: 6:13 error: type `collections::vec::Vec<X>` does not implement any method in scope named `sort`
tmp.rs:6 b.sort();
The compiler should tell us, struct X
doesn't implements Ord
, at least.
Metadata
Metadata
Assignees
Labels
A-diagnosticsArea: Messages for errors, warnings, and lintsArea: Messages for errors, warnings, and lintsE-needs-testCall for participation: An issue has been fixed and does not reproduce, but no test has been added.Call for participation: An issue has been fixed and does not reproduce, but no test has been added.