X Tutup
Skip to content

Avoid emitting a negative activeSignature#586

Merged
renkun-ken merged 1 commit intoREditorSupport:masterfrom
dgkf:avoid-neg-activesig
Dec 7, 2022
Merged

Avoid emitting a negative activeSignature#586
renkun-ken merged 1 commit intoREditorSupport:masterfrom
dgkf:avoid-neg-activesig

Conversation

@dgkf
Copy link
Contributor

@dgkf dgkf commented Dec 7, 2022

Discovered in helix-editor/helix#5023, languageserver was emitting a -1 to a field that has the type uinteger.

Specifically, a negative activeSignature was being emitted by default when no signatures are provided to a signatureHelp request. The spec covers cases where an "out of range" value is emitted, but I don't think this is intended to cover negative values.

As activeSignature is an optional field, I changed it so that the default is to leave the field unspecified. This has resolved the issue in the helix text editor's LSP listener.

Copy link
Member

@renkun-ken renkun-ken left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM Thanks!

@renkun-ken renkun-ken merged commit defae71 into REditorSupport:master Dec 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

X Tutup