Fix wrapping methods with Array return types

This commit is contained in:
Ruslan Mustakov 2020-08-14 01:44:48 +07:00
commit d3e5f91b40
2 changed files with 3 additions and 1 deletions

View file

@ -1,4 +1,4 @@
version = "0.8.0"
version = "0.8.1"
author = "Xored Software, Inc."
description = "Godot Engine bindings"
license = "MIT"

View file

@ -642,6 +642,8 @@ proc doGenerateMethod(tree: PNode, methodBindRegistry: var HashSet[string],
body.add(newPNode(nkVarSection).addChain(newIdentDefs(
retValIdent, ident("Godot" & returnType),
)))
if returnType != "NodePath":
body.add(newCall("initGodot" & returnType, retValIdent))
elif returnType in standardTypes:
addrToAssign = newCall("addr", ident("result"))
elif returnType == "string":