Skip to content

Commit

Permalink
Handle nil signature-help response
Browse files Browse the repository at this point in the history
  • Loading branch information
fhs committed Jun 18, 2023
1 parent 28122bb commit 6067880
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions internal/lsp/acmelsp/remote.go
Original file line number Diff line number Diff line change
Expand Up @@ -227,9 +227,11 @@ func (rc *RemoteCmd) SignatureHelp(ctx context.Context) error {
if err != nil {
return err
}
for _, sig := range sh.Signatures {
fmt.Fprintf(rc.Stdout, "%v\n", sig.Label)
fmt.Fprintf(rc.Stdout, "%v\n", sig.Documentation)
if sh != nil {
for _, sig := range sh.Signatures {
fmt.Fprintf(rc.Stdout, "%v\n", sig.Label)
fmt.Fprintf(rc.Stdout, "%v\n", sig.Documentation)
}
}
return nil
}
Expand Down

0 comments on commit 6067880

Please sign in to comment.