BlueBrain / BlueBrain/hpc-coding-conventions

Default -Wall -Werror and the skipped errors

Open
#33 9 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
10
Forks
6
PR merge metrics
No merged PRs in 30d

Description

@wizmer copied the flags from:
https://github.com/BlueBrain/hpc-coding-conventions/blob/master/cpp/cmake/bob.cmake#L192

What is the plan for choosing what is on that list and what is not?

As the compilers have become more feature-ful, and more aggressive with optimizations, my defensive programming sensibilities have kicked in even stronger. Turning on -Wall & -Werror seems like a necessity to me (with the caveat that one can choose to only enable them for non-Release builds - but the CI should run those for testing).

With that in mind, I like to try and keep the list of exceptions minimal. On that list, for instance, I think `-Wswitch-enum` is an important warning: the fact that one has to make some `switch` statements have to be complete is outweighed by missing cases.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.