Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

display unmatchedSuppression findings #77

Open
firewave opened this issue Jul 25, 2022 · 2 comments
Open

display unmatchedSuppression findings #77

firewave opened this issue Jul 25, 2022 · 2 comments
Assignees

Comments

@firewave
Copy link
Collaborator

We currently suppress unmatchedSuppression findings unconditionally but this is actually something interesting as it will indicate no longer applying (inline) suppressions.

@firewave
Copy link
Collaborator Author

firewave commented Jul 25, 2022

I did not consider unmatchedSuppression important previously since it requires information to be enabled. It has also various bugs which might lead to false positives. It is currently not even enabled in the selfcheck in the Cppcheck CI (which is actually quite bad since we won't be informed about obsolete suppressions i.e. fixed false positives).

While bisecting issues in Cppcheck I needed these messages several times and had to run it on the command-line instead.

firewave added a commit to firewave/clion-cppcheck that referenced this issue Aug 14, 2022
firewave added a commit to firewave/clion-cppcheck that referenced this issue Aug 14, 2022
@firewave
Copy link
Collaborator Author

After enabling it again I realized why I did omit it.

You might get a unmatchedSuppression without a location from global suppressions which are specified via --suppress or in a suppression file which do not have a location.

Since the Cppcheck configuration is global for all projects that is not something you want to see. So we simply need to ignore these findings without a location so we will still get the ones for unmatched inline suppressions.

We should also enable --inline-suppr by default but I will do that in another ticket.

@firewave firewave self-assigned this Aug 15, 2022
firewave added a commit to firewave/clion-cppcheck that referenced this issue Apr 13, 2023
firewave added a commit to firewave/clion-cppcheck that referenced this issue Apr 13, 2023
firewave added a commit to firewave/clion-cppcheck that referenced this issue Apr 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant