diff options
| author | Brad Lewis <22850972+BradLewis@users.noreply.github.com> | 2025-08-11 15:20:10 -0400 |
|---|---|---|
| committer | Brad Lewis <22850972+BradLewis@users.noreply.github.com> | 2025-08-11 15:20:13 -0400 |
| commit | a631a5d232927c658968c3d6040c46b11f2d412b (patch) | |
| tree | 3db51a2123b7b088e0cfeb447ec36188997714b5 /src/server | |
| parent | 3d1b2d482f9c1e0ddb0c3acf2890724f36b51643 (diff) | |
Resolve implicit completions with variadic arguments
Diffstat (limited to 'src/server')
| -rw-r--r-- | src/server/symbol.odin | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/server/symbol.odin b/src/server/symbol.odin index 77c4cb0..cf2c4ed 100644 --- a/src/server/symbol.odin +++ b/src/server/symbol.odin @@ -557,6 +557,10 @@ get_proc_arg_count :: proc(v: SymbolProcedureValue) -> int { get_proc_arg_type_from_index :: proc(value: SymbolProcedureValue, parameter_index: int) -> (^ast.Field, bool) { index := 0 for arg in value.arg_types { + // We're in a variadic arg, so return true + if _, ok := arg.type.derived.(^ast.Ellipsis); ok { + return arg, true + } for name in arg.names { if index == parameter_index { return arg, true |