Skip to content

Add metatable entries for classes with operator overload methods.#135

Open
solemnwarning wants to merge 1 commit intopkulchenko:masterfrom
solemnwarning:metatable-operators
Open

Add metatable entries for classes with operator overload methods.#135
solemnwarning wants to merge 1 commit intopkulchenko:masterfrom
solemnwarning:metatable-operators

Conversation

@solemnwarning
Copy link
Contributor

You can declare operator overloads in a class and genwxbind.lua will generate methods for them that can be called from Lua (e.g. obj:op_add(other_obj)), this commit adds them to the class metatable too, so they can be invoked using Lua operators (e.g. obj + other_obj).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant