forked from rust-lang/rust
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rollup merge of rust-lang#55104 - estebank:addtest, r=alexcrichton
Add test for rust-lang#34229 Fix rust-lang#34229.
- Loading branch information
Showing
2 changed files
with
16 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#[derive(PartialEq)] struct Comparable; | ||
#[derive(PartialEq, PartialOrd)] struct Nope(Comparable); | ||
|
||
fn main() {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
error[E0277]: can't compare `Comparable` with `Comparable` | ||
--> $DIR/issue-34229.rs:2:46 | ||
| | ||
LL | #[derive(PartialEq, PartialOrd)] struct Nope(Comparable); | ||
| ^^^^^^^^^^ no implementation for `Comparable < Comparable` and `Comparable > Comparable` | ||
| | ||
= help: the trait `std::cmp::PartialOrd` is not implemented for `Comparable` | ||
= note: required by `std::cmp::PartialOrd::partial_cmp` | ||
|
||
error: aborting due to previous error | ||
|
||
For more information about this error, try `rustc --explain E0277`. |