Use newer free-threaded language service API#6979
Conversation
There was a problem hiding this comment.
I don't believe we have anything to pass here for cancellation.
There was a problem hiding this comment.
that's fine. we'll continue to have the parameter though in case this is something you hookup in the future. for example, i could imagine a world where the user decides to close VS while we're still loading everything. This would allow youto thread though cancellation if you wanted us to abort.
Our positionhere is: we will support cancellation up through the point where we're still doing computation but haven't done any mutation. once we mutate our actual internal state, we ignore caller-requested cancellation and finish what we're doing. That way our internal models are always in a consistent state.
4c5c568 to
7df3513
Compare
build/import/Packages.targets
Outdated
There was a problem hiding this comment.
We don't expliictly reference the StreamJsonRpc package anywhere in this solution, so this line had no effect.
There was a problem hiding this comment.
A package upgrade must have introduced a Debugger class into a Microsoft.* namespace, as this broke. A using alias didn't help either, hence the fully qualified name here.
There was a problem hiding this comment.
If you put using System.Diagnostics; inside the namespace (not above it like it is now), it would have used the right debugger class as an alternative to fully qualifying it.
Fixes #353 Roslyn recently implemented a free-threaded version of this API, meaning we no longer need to switch to the UI thread before calling it. This commit bumps the package version, removes the thread switch and calls the new API.
7df3513 to
7a7f781
Compare
Fixes #353
Roslyn recently implemented a free-threaded version of this API, meaning we no longer need to switch to the UI thread before calling it.
This commit bumps the package version, removes the thread switch and calls the new API.
cc @CyrusNajmabadi @jasonmalinowski
Microsoft Reviewers: Open in CodeFlow