Skip to content

Move uses of enum to bitflags! where appropriate #14207

Closed
@aturon

Description

@aturon

Where an enum has been used to represent C-style flags (which are then |-ed together and represented as some flavor of uint), we should now be using the bitflags! macro, which provides stronger type safety guarantees at no cost.

This gist gives a rough grep of the code base where enums with custom discriminants are being used. Some of these are genuinely enums, while others are being used as flags and should be converted to use bitflags! instead.

Metadata

Metadata

Assignees

No one assigned

    Labels

    E-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions