You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Agreed, this would be nice... I don't think function overloading is supported in JavaScript, but maybe something could be done with a "dispatching" dukglue-bound constructor method that takes variable args and calls the best constructor depending on the number/type of args?
Or having a way to set default arguments for dukglue-bound functions...? For example, in your example, maybe there's a way the x_, y_ and z_ arguments could be defaulted to 0, which would support a constructor with 0, 1, 2 or 3 arguments...
If I try to register multiple constructors for a class, only one of them is used:
I register both constructors:
but now I can't use the first constructor.
The text was updated successfully, but these errors were encountered: