active_parameter
out of range for first param of multi-word instructions
#24
Labels
bug
Something isn't working
When getting the arg index for signature help on multi-word instructions, we offset the index by -1 to account for the extra arg:
spinasm-lsp/src/spinasm_lsp/server.py
Lines 359 to 360 in 4d6e946
On the first parameter, this makes the arg index -1 which is out of range for
SignatureHelp.active_parameter
, leading to aValueError
. The offset should only be applied ifarg_idx != 0
. The existing check forarg_idx != -1
can be removed, since that assumed that-1
would correspond with the final parameter.The text was updated successfully, but these errors were encountered: