2020-09-26 17:20:14 -04:00
|
|
|
error[E0599]: the method `is_subset` exists for reference `&HashSet<T>`, but its trait bounds were not satisfied
|
2021-10-13 16:07:22 +00:00
|
|
|
--> $DIR/issue-35677.rs:7:10
|
2018-12-12 15:58:27 -08:00
|
|
|
|
|
2019-02-11 11:58:56 +01:00
|
|
|
LL | this.is_subset(other)
|
2020-09-26 17:20:14 -04:00
|
|
|
| ^^^^^^^^^ method cannot be called on `&HashSet<T>` due to unsatisfied trait bounds
|
2018-12-12 15:58:27 -08:00
|
|
|
|
|
2020-09-26 17:20:14 -04:00
|
|
|
= note: the following trait bounds were not satisfied:
|
2020-09-02 10:40:56 +03:00
|
|
|
`T: Eq`
|
2023-01-12 19:53:01 +00:00
|
|
|
`T: PartialEq`
|
|
|
|
which is required by `T: Eq`
|
2020-09-02 10:40:56 +03:00
|
|
|
`T: Hash`
|
2021-10-13 16:07:22 +00:00
|
|
|
help: consider restricting the type parameters to satisfy the trait bounds
|
|
|
|
|
|
2023-01-13 20:50:34 +00:00
|
|
|
LL | fn is_subset<T>(this: &HashSet<T>, other: &HashSet<T>) -> bool where T: Eq, T: Hash {
|
|
|
|
| ++++++++++++++++++++
|
2018-12-12 15:58:27 -08:00
|
|
|
|
2023-11-21 15:44:16 +00:00
|
|
|
error: aborting due to 1 previous error
|
2018-12-12 15:58:27 -08:00
|
|
|
|
2018-12-16 20:23:27 +03:00
|
|
|
For more information about this error, try `rustc --explain E0599`.
|