From 626202b451dc6bfb08e7d3d44cf6c4a33864302c Mon Sep 17 00:00:00 2001 From: Graham Date: Sat, 7 Mar 2020 17:35:35 +0000 Subject: [PATCH] Move isMethodRenamable below createMethodMapping for consistency Signed-off-by: Graham --- .../dev/openrs2/deob/remap/TypedRemapper.kt | 34 +++++++++---------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/deob/src/main/java/dev/openrs2/deob/remap/TypedRemapper.kt b/deob/src/main/java/dev/openrs2/deob/remap/TypedRemapper.kt index 475051740e..ac537a2408 100644 --- a/deob/src/main/java/dev/openrs2/deob/remap/TypedRemapper.kt +++ b/deob/src/main/java/dev/openrs2/deob/remap/TypedRemapper.kt @@ -218,23 +218,6 @@ class TypedRemapper private constructor( return generateName(prefixes, prefix.indefiniteArticle() + prefix.capitalize()) } - fun isMethodRenamable(classPath: ClassPath, partition: DisjointSet.Partition): Boolean { - for (method in partition) { - val clazz = classPath[method.owner]!! - - if (method.name in EXCLUDED_METHODS || clazz.dependency) { - return false - } - - val access = clazz.getAccess(MemberDesc(method)) - if (access != null && access and Opcodes.ACC_NATIVE != 0) { - return false - } - } - - return true - } - private fun createMethodMapping( classPath: ClassPath, disjointSet: DisjointSet @@ -255,5 +238,22 @@ class TypedRemapper private constructor( return mapping } + + fun isMethodRenamable(classPath: ClassPath, partition: DisjointSet.Partition): Boolean { + for (method in partition) { + val clazz = classPath[method.owner]!! + + if (method.name in EXCLUDED_METHODS || clazz.dependency) { + return false + } + + val access = clazz.getAccess(MemberDesc(method)) + if (access != null && access and Opcodes.ACC_NATIVE != 0) { + return false + } + } + + return true + } } }