Skip to content

Clarify outlives requirements on associated types #20303

@nikomatsakis

Description

@nikomatsakis

Right now we check that the outlives requirements in the trait are met, but say nothing about an associated type. I think the correct thing is to treat them exactly like type parameters, basically. So we should be checking that they outlive the relevant region bound -- and we should assume that they outlive the current fn, but nothing else. This seems to be roughly equivalent to the current treatment of type parameters (for better/worse).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions