From 9030ddf062d5bb80075acc7b66e4e7152e301c98 Mon Sep 17 00:00:00 2001 From: joe Date: Fri, 29 Nov 2024 22:54:25 +0000 Subject: [PATCH] Don't get polymorphic references for constructors --- .../net/earthcomputer/clientcommands/test/ReferencesFinder.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/test/java/net/earthcomputer/clientcommands/test/ReferencesFinder.java b/src/test/java/net/earthcomputer/clientcommands/test/ReferencesFinder.java index bf4078aa..379e0a7c 100644 --- a/src/test/java/net/earthcomputer/clientcommands/test/ReferencesFinder.java +++ b/src/test/java/net/earthcomputer/clientcommands/test/ReferencesFinder.java @@ -260,7 +260,7 @@ public ReferencesSet findMethodReferences(String owner, String name, String desc // we don't know whether the method is virtual or not yet, so find the non-virtual method first and then check // if it's non-virtual ReferencesSet nonVirtualReferences = resolveNonVirtualMethod(classInfo, new NameAndDesc(name, desc), index::get); - if (nonVirtualReferences != null && (nonVirtualReferences.access & (Opcodes.ACC_PRIVATE | Opcodes.ACC_STATIC)) != 0) { + if (nonVirtualReferences != null && ((nonVirtualReferences.access & (Opcodes.ACC_PRIVATE | Opcodes.ACC_STATIC)) != 0 || "".equals(name))) { return nonVirtualReferences; }