Fix constructor matchng logic for luajava lib.
This commit is contained in:
@@ -368,8 +368,7 @@ public class LuajavaLib extends VarArgFunction {
|
|||||||
int besti = 0;
|
int besti = 0;
|
||||||
for ( int i=0, size=cons.length; i<size; i++ ) {
|
for ( int i=0, size=cons.length; i<size; i++ ) {
|
||||||
Constructor con = cons[i];
|
Constructor con = cons[i];
|
||||||
int paramType = LuajavaLib.paramTypeFromSig(paramssig, 0);
|
int s = CoerceLuaToJava.scoreParamTypes(paramssig, con.getParameterTypes());
|
||||||
int s = CoerceLuaToJava.scoreParamTypes(paramType, con.getParameterTypes());
|
|
||||||
if ( s < bests ) {
|
if ( s < bests ) {
|
||||||
bests = s;
|
bests = s;
|
||||||
besti = i;
|
besti = i;
|
||||||
|
|||||||
Reference in New Issue
Block a user