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

made CppCheckExecutor::check_wrapper() const #7396

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

firewave
Copy link
Collaborator

No description provided.

@firewave
Copy link
Collaborator Author

We do not detect this ourselves because of the conditional code inside.

I wonder if we could add a flag which does not omit such warnings similar to --emit-duplicates but I guess in this case it is not some global logic you could put a switch on.

@firewave
Copy link
Collaborator Author

We do not detect this ourselves because of the conditional code inside.

This is just an assumption. I do not have actually checked this (yet).

@firewave
Copy link
Collaborator Author

This is just an assumption. I do not have actually checked this (yet).

I confirmed that it is indeed omitted because of the preprocessor checks. But I do not see where the bailout happens in the code (I also wonder if we should write a debug message about the bailout).

@firewave
Copy link
Collaborator Author

But I do not see where the bailout happens in the code

It is the mTokenizer->hasIfdef() call in CheckClass::checkConstFunc().

@firewave
Copy link
Collaborator Author

It is the mTokenizer->hasIfdef() call in CheckClass::checkConstFunc().

I filed some tickets about possible improvements in the handling:
https://trac.cppcheck.net/ticket/13740
https://trac.cppcheck.net/ticket/13741

@firewave firewave marked this pull request as draft April 2, 2025 18:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant