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

Improve error reporting during indexing #8

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

psalz
Copy link
Member

@psalz psalz commented Aug 7, 2024

The previous behavior was to basically suppress all error diagnostics generated by Clang during indexing, and only rely on the return value of ClangTool::run to decide whether a file was parsed correctly or not.

For irrecoverable errors such as missing files this doesn't give one much to work with. The new behavior is to parse all diagnostics and check for missing files, and if there are some, print those immediately.

For other errors that may be encountered, we now keep count of how many there are, and offer the option to print them using --verbose output.

The previous behavior was to basically suppress all error diagnostics
generated by Clang during indexing, and only rely on the return value of
`ClangTool::run` to decide whether a file was parsed correctly or not.

For irrecoverable errors such as missing files this doesn't give one
much to work with. The new behavior is to parse all diagnostics and
check for missing files, and if there are some, print those immediately.

For other errors that may be encountered, we now keep count of how many
there are, and offer the option to print them using --verbose output.
@PeterTh
Copy link
Collaborator

PeterTh commented Aug 7, 2024

Maybe provide a hint to fix compile_commands.json at the end if there are errors?

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.

2 participants