Skip to content

lint generic type argument of a generic type that could be : ?Sized #1368

Open
@oli-obk

Description

@oli-obk
struct A<T: Trait>(Box<T>);

should lint that one should write T: Trait + ?Sized.

Motivation: http://stackoverflow.com/questions/40846232/rust-compiler-does-not-see-structure-as-sized

To reduce false positives, this should only lint if the impl X for A and impl A, will continue working if they are also changed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-lintArea: New lintsE-hardCall for participation: This a hard problem and requires more experience or effort to work onL-correctnessLint: Belongs in the correctness lint groupL-unnecessaryLint: Warn about unnecessary codeT-middleType: Probably requires verifiying types

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions