johnthagen/clion-cppcheck

Cppcheck should only be invoked with a single configuration

Offen

#34 geöffnet am 09.04.2020

 (5 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)Java (7 Forks)github user discovery
enhancementhelp wanted

Repository-Metriken

Stars
 (37 Sterne)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

Environment

  • Operating System (e.g. Ubuntu 16.04 x64): Windows 10
  • IDE Version (e.g. CLion 2016.3.2): Clion 2020.1 (201.6668.86)
  • Cppcheck executable version (cppcheck --version): 1.90
  • Cppcheck plugin version: 1.4.2

Expected behaviour

The inspections show issues in active code only.

Actual behaviour

The inspection may should code in non-active (i.e. _MSC_VER although GCC is being used) blocks.

If Cppcheck is invoked with just a source file it tries to detect and process all configuration (i.e. defines) in the source. In case of the IDE it should only do a scan for that current configuration. This requires the plugin to get this from the IDE (if possible) and provide it to the call.

Contributor Guide