swiftlang / swift-package-manager

The Package Manager for the Swift Programming Language
Apache License 2.0
9.72k stars 1.34k forks source link

[Build] Use a separate scope while constructing a build plan #7865

Closed xedin closed 1 month ago

xedin commented 1 month ago

Motivation:

We need to use a separate inner scope to capture any problems during build plan construction and make a decision to stop based on that. The current logic checks the scope that is passed in which tracks errors emitted elsewhere.

Modifications:

Result:

sourcekit-lsp no longer fails if there is no Package.resolved - https://github.com/swiftlang/sourcekit-lsp/pull/1618

xedin commented 1 month ago

https://github.com/swiftlang/sourcekit-lsp/pull/1618 @swift-ci please test