Skip to content

rustc should check that for each impl of a trait, impls of the supertraits exist #4055

Closed
@brson

Description

@brson

On my inheritance branch this currently compiles

trait A { }

trait B: A { }

enum Foo = int;

impl Foo: B { }

I don't think there's anything unsound about this because rustc will generate an error as soon as you try to use trait A on Foo, but it should still be caught by looking at the impl of B.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions