Extend HIR WF checking to fields

This commit is contained in:
Aaron Hill 2021-07-20 10:56:33 -05:00
parent f913a4fe90
commit 0ebd6e4891
No known key found for this signature in database
GPG key ID: B4087E510E98B164
6 changed files with 15 additions and 13 deletions

View file

@ -1,8 +1,8 @@
error[E0038]: the trait `Qiz` cannot be made into an object
--> $DIR/issue-19380.rs:11:9
--> $DIR/issue-19380.rs:11:29
|
LL | foos: &'static [&'static (dyn Qiz + 'static)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ `Qiz` cannot be made into an object
| ^^^^^^^^^^^^^^^^^ `Qiz` cannot be made into an object
|
note: for a trait to be "object safe" it needs to allow building a vtable to allow the call to be resolvable dynamically; for more information visit <https://doc.rust-lang.org/reference/items/traits.html#object-safety>
--> $DIR/issue-19380.rs:2:6