summary refs log tree commit diff
path: root/src/test/ui/bound-suggestions.stderr
blob: 010f95d8ad6f00153da147a3c1a43ebe7942c59a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
error[E0277]: `impl Sized` doesn't implement `Debug`
  --> $DIR/bound-suggestions.rs:9:22
   |
LL |     println!("{:?}", t);
   |                      ^ `impl Sized` cannot be formatted using `{:?}` because it doesn't implement `Debug`
   |
   = note: required by `std::fmt::Debug::fmt`
   = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider further restricting this bound
   |
LL | fn test_impl(t: impl Sized + Debug) {
   |                            ^^^^^^^

error[E0277]: `T` doesn't implement `Debug`
  --> $DIR/bound-suggestions.rs:15:22
   |
LL |     println!("{:?}", t);
   |                      ^ `T` cannot be formatted using `{:?}` because it doesn't implement `Debug`
   |
   = note: required by `std::fmt::Debug::fmt`
   = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider restricting type parameter `T`
   |
LL | fn test_no_bounds<T: Debug>(t: T) {
   |                    ^^^^^^^

error[E0277]: `T` doesn't implement `Debug`
  --> $DIR/bound-suggestions.rs:21:22
   |
LL |     println!("{:?}", t);
   |                      ^ `T` cannot be formatted using `{:?}` because it doesn't implement `Debug`
   |
   = note: required by `std::fmt::Debug::fmt`
   = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider further restricting this bound
   |
LL | fn test_one_bound<T: Sized + Debug>(t: T) {
   |                            ^^^^^^^

error[E0277]: `Y` doesn't implement `Debug`
  --> $DIR/bound-suggestions.rs:27:30
   |
LL |     println!("{:?} {:?}", x, y);
   |                              ^ `Y` cannot be formatted using `{:?}` because it doesn't implement `Debug`
   |
   = note: required by `std::fmt::Debug::fmt`
   = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider further restricting type parameter `Y`
   |
LL | fn test_no_bounds_where<X, Y>(x: X, y: Y) where X: std::fmt::Debug, Y: Debug {
   |                                                                   ^^^^^^^^^^

error[E0277]: `X` doesn't implement `Debug`
  --> $DIR/bound-suggestions.rs:33:22
   |
LL |     println!("{:?}", x);
   |                      ^ `X` cannot be formatted using `{:?}` because it doesn't implement `Debug`
   |
   = note: required by `std::fmt::Debug::fmt`
   = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider further restricting this bound
   |
LL | fn test_one_bound_where<X>(x: X) where X: Sized + Debug {
   |                                                 ^^^^^^^

error[E0277]: `X` doesn't implement `Debug`
  --> $DIR/bound-suggestions.rs:39:22
   |
LL |     println!("{:?}", x);
   |                      ^ `X` cannot be formatted using `{:?}` because it doesn't implement `Debug`
   |
   = note: required by `std::fmt::Debug::fmt`
   = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider further restricting type parameter `X`
   |
LL | fn test_many_bounds_where<X>(x: X) where X: Sized, X: Sized, X: Debug {
   |                                                            ^^^^^^^^^^

error: aborting due to 6 previous errors

For more information about this error, try `rustc --explain E0277`.