-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Swift: add more debug logs #19384
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
Swift: add more debug logs #19384
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds additional debug log statements to improve the traceability of the Swift extractor's operation. Key changes include:
- New LOG_DEBUG calls in the Observer class methods (main.cpp) to log function invocation.
- Additional LOG_DEBUG messages in SwiftExtractor.cpp to report module loading and processing activities.
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
File | Description |
---|---|
swift/extractor/main.cpp | Added debug logs in parsedArgs, configuredCompiler, performedCompilation, and markSuccessfullyExtractedFiles methods. |
swift/extractor/SwiftExtractor.cpp | Added debug logs for module loading count and for decisions to skip or process modules. |
codeql::extractSwiftFiles(state, compiler); | ||
codeql::extractSwiftInvocation(state, compiler, invocationTrap); | ||
codeql::extractExtractLazyDeclarations(state, compiler); | ||
} | ||
|
||
void markSuccessfullyExtractedFiles() { | ||
LOG_DEBUG("{}()", __func__); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nitpick] Consider standardizing the log message format across Observer methods. For example, if most methods use "{}(...)", you might adjust this log to match for consistency.
LOG_DEBUG("{}()", __func__); | |
LOG_DEBUG("{}(...)", __func__); |
Copilot uses AI. Check for mistakes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. The Copilot suggestion makes sense to me, so maybe apply it?
No description provided.