Skip to content

Request: enum_type Additions #1216

@drewr95

Description

@drewr95

I'd like a couple of possible additions/improvements using enum_type.h:

  1. I'm getting a linter warning when using enum_type because one of the constructors is missing an explicit marker.
    warning: single-argument constructors must be marked explicit to avoid unintentional implicit conversions [google-explicit-constructor,hicpp-explicit-conversions]
  2. It would be nice to utilize etl::to_underlying for the underlying value_type typedef so that duplication is removed. If the intent is to not use underlying types for enum, maybe it's best to have a C++11+ version vs a legacy version?

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