cgen: use gen_varg var in condition

pull/4550/head
joe-conigliaro 2020-04-22 13:31:24 +10:00
parent c1e8612624
commit c35e0e49ce
1 changed files with 1 additions and 1 deletions

View File

@ -403,7 +403,7 @@ fn (g mut Gen) call_args(args []ast.CallArg, expected_types []table.Type) {
}
arg_no++
}
if is_variadic && !is_forwarding_varg {
if gen_vargs {
varg_type := expected_types[expected_types.len - 1]
struct_name := 'varg_' + g.typ(varg_type).replace('*', '_ptr')
variadic_count := args.len - arg_no