Skip to content

Commit e02ab1e

Browse files
committed
gopls/internal/lsp/source: fix command func check signature for trigger comma
1 parent 2f14ba2 commit e02ab1e

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

gopls/internal/lsp/source/signature_help_gox.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,8 +124,9 @@ FindCall:
124124
var sigType types.Type
125125
if callExpr != nil {
126126
sigType = pkg.GopTypesInfo().TypeOf(callExpr.Fun)
127-
} else {
128-
sigType = cmdObj.Type()
127+
}
128+
if sigType == nil && obj != nil {
129+
sigType = obj.Type()
129130
}
130131
if sigType == nil {
131132
return nil, 0, 0, fmt.Errorf("cannot get type for Fun %[1]T (%[1]v)", callExpr.Fun)

0 commit comments

Comments
 (0)