Skip to content

[5.7][Parseable Output] Emit parseable messages on failure in CompilerInstance.setup #58902

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

Merged
merged 1 commit into from
May 31, 2022

Conversation

artemcm
Copy link
Contributor

@artemcm artemcm commented May 13, 2022

Cherry-pick of #58881

FrontendTool sets up diagnostic infrastructure early and suppresses stdout diagnostics if frontend-parseable-output is enabled. It then calls CompilerInstance.setup which may fail - if it fails, we exit early. But that means we have not gotten a chance to emit parseable-output.

This change moves emission of the began parseable message to before CompilerInstance.setup, and ensures that a corresponding finished message is emitted if the setup fails.

Resolves rdar://93187783

…tance.setup`

FrontendTool sets up diagnostic infrastructure early and suppresses stdout diagnostics if frontend-parseable-output is enabled. It then calls `CompilerInstance.setup` which may fail - if it fails, we exit early. But that means we have not gotten a chance to emit parseable-output.

This change moves emission of the `began` parseable message to before `CompilerInstance.setup`, and ensures that a corresponding `finished` message is emitted if the setup fails.

Resolves rdar://93187783
@artemcm artemcm added the r5.7 label May 13, 2022
@artemcm artemcm requested a review from a team as a code owner May 13, 2022 19:32
@artemcm
Copy link
Contributor Author

artemcm commented May 13, 2022

@swift-ci please test

@artemcm
Copy link
Contributor Author

artemcm commented May 31, 2022

@swift-ci please test

@artemcm artemcm merged commit 2663d48 into swiftlang:release/5.7 May 31, 2022
@AnthonyLatsis AnthonyLatsis added 🍒 release cherry pick Flag: Release branch cherry picks swift 5.7 labels Jan 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🍒 release cherry pick Flag: Release branch cherry picks swift 5.7
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants