Review how LS features going to work on top of a partially compiled AST #35087
Labels
IceBox
Older issues that are not being actively worked on but may be revisited in the future.
Team/LanguageServer
Language Server Implementation related issues. #Compiler
Type/Task
Description:
$subject.
When the compiler crashes currently we catch the exception and add a compiler diagnostic saying
"Compilation failed due to: "
.In this scenario, the compilation is only partially done. But, the LS is not aware of it. So LS features working on top of such a situation could lead to wrong suggestions, etc.
There could be LS test cases that are false positives because they are written on top of a partial compilation. With PR Fix unhandled compiler exceptions being not result in test failures #34984 if there is any such test case that will fail. (But this is only a temporary solution).
As @pubudu91 said we use the same compilationContext between subsequent compilations. If there is a crash, we need to flush it to avoid any unpredictable results.
[1] and [2] are somewhat okay for now. But, we need to fix [3] immediately.
The text was updated successfully, but these errors were encountered: