Skip to content

Implicit fallthroughs prevent compiler warning enablement #455

Open
@r-barnes

Description

Describe the bug
There are a number of places like this where the code does an implicit fallthrough.

Could these please be marked with __attribute__((fallthrough)) (for C code) or [[fallthrough]] (for C++17 and above code)? That enables the use of -Wimplicit-fallthrough which requires that all fallthroughs be explicit, reducing potential error surfaces.

To Reproduce
To assist in reproducing the bug, please include the following:

  1. Command/code being executed: N/A
  2. Python version and OS: N/A
  3. pip version: master
  4. Output of pip list or conda list: N/A

Expected behavior
Fallthroughs are marked explicitly.

Additional context
Add any other context about the problem here.

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions