Description
The LSP crashes with exit code 101 when opening a file containing a .macro directive.
Steps to Reproduce
Create a file with the following minimal content:
.macro test_macro
lda #$01
.endmacro
Open it in Neovim. The LSP immediately crashes.
Error
thread 'main' panicked at lsp/src/state.rs:66:24:
slice index starts at 286 but ends at 273
Environment
- OS: Arch Linux
- Neovim version: v0.12.1
- ca65-lsp version: main (installed with rust)
Edits:
- I just found (and tried) the "fix-define-macro" branch. No luck with it, same error occurred.
- New info! Crashes specifically only occur when a macro is defined in a ".s" file. If the same macro is added to a ".inc" file (even if the file is included in a ".s") no crashes occur. Also, I still get autocomplete and everything in the ".inc", so that is a workable fix for now. IE, I will define all macros in ".inc" and leave them out of ".s" (just include instead). This goes for both the main branch, as well as the "fix-define-macro" branch, no noticable differences.
(Btw, I did use ai to figure out what to include in this issue post/figure out how to write it up. BUT I did find the issue myself, and it is actually causing me problems.)
Description
The LSP crashes with exit code 101 when opening a file containing a
.macrodirective.Steps to Reproduce
Create a file with the following minimal content:
Open it in Neovim. The LSP immediately crashes.
Error
thread 'main' panicked at lsp/src/state.rs:66:24:
slice index starts at 286 but ends at 273
Environment
Edits:
(Btw, I did use ai to figure out what to include in this issue post/figure out how to write it up. BUT I did find the issue myself, and it is actually causing me problems.)