rust/tests/ui/trait-bounds/sort-missing-ord-bound.stderr
reddevilmidzy 1bd997a452 Cleaned up some tests
Split invalid-compile-flags into run-pass & invalid

Update tests/ui/README.md
2025-12-16 02:10:08 +09:00

17 lines
489 B
Text

error[E0277]: the trait bound `X: Ord` is not satisfied
--> $DIR/sort-missing-ord-bound.rs:8:7
|
LL | b.sort();
| ^^^^ the trait `Ord` is not implemented for `X`
|
note: required by a bound in `slice::<impl [T]>::sort`
--> $SRC_DIR/alloc/src/slice.rs:LL:COL
help: consider annotating `X` with `#[derive(Ord)]`
|
LL + #[derive(Ord)]
LL | struct X {
|
error: aborting due to 1 previous error
For more information about this error, try `rustc --explain E0277`.