Elektrine lite

← Feed

@anselmschueler@ieji.de

Post #2489049

2025-05-21 23:50 UTC

@rain@hachyderm.io Is the upcast method just a way to reify the fact that it's covariant?

Replies (1)

  • @rain@hachyderm.io 2025-05-21 23:54

    @anselmschueler@ieji.de yep! https://docs.rs/iddqd/latest/iddqd/macro.id_upcast.html Ideally I'd be able to put a covariance bound on the trait's associated type itself, but there's no way to do that in stable Rust

    Open ##2489050