@@ -25,15 +25,16 @@ error[E0277]: the trait bound `&mut bool: __private::not::Bool` is not satisfied
25
25
| | the trait `__private::not::Bool` is not implemented for `&mut bool`
26
26
| required by a bound introduced by this call
27
27
|
28
- = help: the following other types implement trait `__private::not::Bool`:
29
- &bool
30
- bool
31
28
= note: `__private::not::Bool` is implemented for `&bool`, but not for `&mut bool`
32
29
note: required by a bound in `anyhow::__private::not`
33
30
--> src/lib.rs
34
31
|
35
32
| pub fn not(cond: impl Bool) -> bool {
36
33
| ^^^^ required by this bound in `not`
34
+ help: consider dereferencing here
35
+ |
36
+ 29 | Bool(cond) => ensure!(*cond),
37
+ | +
37
38
38
39
error[E0277]: the trait bound `DerefBool: __private::not::Bool` is not satisfied
39
40
--> tests/ui/ensure-nonbool.rs:33:13
@@ -44,14 +45,15 @@ error[E0277]: the trait bound `DerefBool: __private::not::Bool` is not satisfied
44
45
| | the trait `__private::not::Bool` is not implemented for `DerefBool`
45
46
| required by a bound introduced by this call
46
47
|
47
- = help: the following other types implement trait `__private::not::Bool`:
48
- &bool
49
- bool
50
48
note: required by a bound in `anyhow::__private::not`
51
49
--> src/lib.rs
52
50
|
53
51
| pub fn not(cond: impl Bool) -> bool {
54
52
| ^^^^ required by this bound in `not`
53
+ help: consider dereferencing here
54
+ |
55
+ 33 | ensure!(*db);
56
+ | +
55
57
56
58
error[E0277]: the trait bound `&DerefBool: __private::not::Bool` is not satisfied
57
59
--> tests/ui/ensure-nonbool.rs:34:13
0 commit comments