You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
assoc_typ_dyn.rs:16:28: 16:31 error: unsupported associated type binding
assoc_typ_dyn.rs:16 let x = box Bar as Box<Foo>;
^~~
assoc_typ_dyn.rs:16:13: 16:32 error: type mismatch: the type `Bar` implements the trait `Foo<int>`, but the trait `Foo<[type error]>` is required (expected type error, found int)
assoc_typ_dyn.rs:16 let x = box Bar as Box<Foo>;
^~~~~~~~~~~~~~~~~~~
assoc_typ_dyn.rs:16:13: 16:32 note: the trait `Foo` must be implemented for the cast to the object type `Foo<[type error]>`
assoc_typ_dyn.rs:16 let x = box Bar as Box<Foo>;
^~~~~~~~~~~~~~~~~~~
Not only does this mention type errors when it probably shouldn’t, but it also seems to be mistaking the associated type for a type parameter. Changing the cast to as Box<Foo<int>> as it seems to suggest doesn’t work, and the syntax from the RFC (Box<Foo<T = int>>) doesn’t seem to be implemented yet.
The text was updated successfully, but these errors were encountered:
This fails to compile with:
Not only does this mention type errors when it probably shouldn’t, but it also seems to be mistaking the associated type for a type parameter. Changing the cast to
as Box<Foo<int>>
as it seems to suggest doesn’t work, and the syntax from the RFC (Box<Foo<T = int>>
) doesn’t seem to be implemented yet.The text was updated successfully, but these errors were encountered: