Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • mesa mesa
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 2,699
    • Issues 2,699
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 910
    • Merge requests 910
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Mesa
  • mesamesa
  • Merge requests
  • !14587

Initializer-overrides warnings

  • Review changes

  • Download
  • Email patches
  • Plain diff
Open Thomas Andersen requested to merge phomes/mesa:initilizer-overrides-gcc into main Jan 17, 2022
  • Overview 2
  • Commits 8
  • Pipelines 2
  • Changes 6

Warnings about initializer overrides are a mixed bag. Sometimes they find real bugs but sometimes they just warn about intended overrides.

Clang has -Winitializer-overrids in -Wall. The GCC counterpart is -Woverride-init and is in -Wextra. We therefore see this type of warning only on clang by default.

To make clang warning-clean and thus able to build in CI without any no-error=* the relevant warnings have been corrected. In this MR the few cases of intentional overrides are ignored with #pragma's.

Clang will now spot regressions in the CI. To avoid having to catch all new warnings late in the CI -Woverride-init is also added to the default warnings flags. Developers using GCC will now see the warnings before hitting them in the CI.

Assignee
Assign to
Reviewer
Request review from
Time tracking
Source branch: initilizer-overrides-gcc