summaryrefslogtreecommitdiff
path: root/tests/ui/coercion/coerce-issue-49593-box-never.nofallback.stderr
blob: 7222af43b0137146032b440da9007b8db6a8ddf0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
error[E0277]: the trait bound `(): std::error::Error` is not satisfied
  --> $DIR/coerce-issue-49593-box-never.rs:18:5
   |
LL |     Box::<_ /* ! */>::new(x)
   |     ^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::error::Error` is not implemented for `()`
   |
   = note: required for the cast from `Box<()>` to `Box<(dyn std::error::Error + 'static)>`

error[E0277]: the trait bound `(): std::error::Error` is not satisfied
  --> $DIR/coerce-issue-49593-box-never.rs:24:5
   |
LL |     raw_ptr_box::<_ /* ! */>(x)
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::error::Error` is not implemented for `()`
   |
   = note: required for the cast from `*mut ()` to `*mut (dyn std::error::Error + 'static)`

error: aborting due to 2 previous errors

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