From 9caeb8d29658cd4cc7bfa0b5983595e6b39f3bff Mon Sep 17 00:00:00 2001 From: Karroffel Date: Tue, 16 May 2017 09:00:17 +0200 Subject: [PATCH] made msvc happier --- binding_generator.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/binding_generator.py b/binding_generator.py index 887175c8..28139138 100644 --- a/binding_generator.py +++ b/binding_generator.py @@ -282,8 +282,9 @@ def generate_class_implementation(icalls, used_classes, c): if method["is_virtual"] or method["has_varargs"]: - - source.append("\tVariant __given_args[" + str(len(method["arguments"])) + "];") + + if len(method["arguments"]) != 0: + source.append("\tVariant __given_args[" + str(len(method["arguments"])) + "];") for i, argument in enumerate(method["arguments"]): source.append("\tgodot_variant_new_nil((godot_variant *) &__given_args[" + str(i) + "]);")