Skip to content

Add checkstyle rules for List.of() / Set.of() / Map.of() #31973

@mhalbritter

Description

@mhalbritter

We decided to not use List.of(), Set.of() and Map.of(), preferring Collections.emptyList(), etc. We should have a checkstyle rule to prevent creeping them accidentally in the codebase. Note that we only want to prohibit the non-argument versions, using List.of(a) etc. is fine.

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: supersededAn issue that has been superseded by another

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions