Skip to content

The Output should not be an association type of the FnOnce #108490

Closed as not planned
@823984418

Description

@823984418

Currently, we require that the lifecycle that appears in an association type appear in a generic type.
This is to fix #32330 .
But this because the Output is an associative type of the function.


trait F {
    type Output;
}

Except for functions, no same type can implement different lifecycle Output.
So the Output as an association type is just an error.

See #33685 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions