-
Notifications
You must be signed in to change notification settings - Fork 196
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
Crashing String.slice after editing file/module endings #1002
Comments
That's most likely race conditions between publishing diagnostics and source file changes. This line assumes the source file has the line with error
|
Shouldn't the file already being read at this point, how can this differ? |
Async parsing and async text document synchronisation. When the diagnostic is being published the line is not there anymore and we need the line to convert UTF8 code points to UTF16. I know what needs fixing here :) |
Thank you very much for your work! 🙏 |
Environment
Current behavior
The LS seems to crash when adding/removing the last
end
in this module:Change
to
It might be, that the appearance/disappearance of the last line/last "newline" plays a role here. I noticed my Editor currently seems to strip the last line and this happens a lot when quickly edditing in the last section of the file.
Log
The text was updated successfully, but these errors were encountered: