aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDaniel Gavin <danielgavin5@hotmail.com>2021-05-09 22:57:41 +0200
committerDaniel Gavin <danielgavin5@hotmail.com>2021-05-09 22:57:41 +0200
commitff3fd70204fd7693f590d66c0019686c6590d9ab (patch)
treea5d47497e54ff9f0d5a189e1fa0f4b3dcb4c8bf2 /src
parent84d844bd4ad9320d00ea5f025a9ca44bf74c6ee7 (diff)
parent9fd0db11bbf66a12f051ea3e95444b3291c760d5 (diff)
Merge branch 'procedure-arguments'
Diffstat (limited to 'src')
-rw-r--r--src/common/ast.odin1
-rw-r--r--src/server/analysis.odin2
2 files changed, 2 insertions, 1 deletions
diff --git a/src/common/ast.odin b/src/common/ast.odin
index 839c7f5..d110441 100644
--- a/src/common/ast.odin
+++ b/src/common/ast.odin
@@ -673,6 +673,7 @@ build_string_node :: proc(node: ^ast.Node, builder: ^strings.Builder) {
case Basic_Directive:
strings.write_string(builder, n.name);
case Ellipsis:
+ strings.write_string(builder, "..");
build_string(n.expr, builder);
case Proc_Lit:
build_string(n.type, builder);
diff --git a/src/server/analysis.odin b/src/server/analysis.odin
index c90e2fe..af58546 100644
--- a/src/server/analysis.odin
+++ b/src/server/analysis.odin
@@ -645,7 +645,7 @@ resolve_function_overload :: proc(ast_context: ^AstContext, group: ast.Proc_Grou
next_fn: if f, ok := resolve_type_expression(ast_context, arg_expr); ok {
- if ast_context.call == nil {
+ if ast_context.call == nil || len(ast_context.call.args) == 0 {
append(&candidates, f);
break next_fn;
}