docs: fixup

This commit is contained in:
Lucaskyy 2022-04-08 22:54:23 +02:00 committed by oSumAtrIX
parent a8653fe6a0
commit 066ad274ed
No known key found for this signature in database
GPG Key ID: A9B3094ACDB604B4
2 changed files with 6 additions and 3 deletions

View File

@ -4,7 +4,8 @@ import app.revanced.patcher.proxy.mutableTypes.MutableClass
import org.jf.dexlib2.iface.ClassDef import org.jf.dexlib2.iface.ClassDef
/** /**
* A proxy class for a [ClassDef] * A proxy class for a [ClassDef].
*
* A class proxy simply holds a reference to the original class * A class proxy simply holds a reference to the original class
* and creates a mutable clone for the original class if needed. * and creates a mutable clone for the original class if needed.
* @param immutableClass The class to proxy * @param immutableClass The class to proxy
@ -18,8 +19,9 @@ class ClassProxy(
internal lateinit var mutatedClass: MutableClass internal lateinit var mutatedClass: MutableClass
/** /**
* Creates and returns a mutable clone of the original class * Creates and returns a mutable clone of the original class.
* A patch should always use the original immutable class reference to avoid unnecessary allocations for the mutable class * A patch should always use the original immutable class reference
* to avoid unnecessary allocations for the mutable class.
*/ */
fun resolve(): MutableClass { fun resolve(): MutableClass {
if (!proxyUsed) { if (!proxyUsed) {

View File

@ -29,6 +29,7 @@ class InlineSmaliCompiler {
* as that will result in exceptions since the labels cannot be calculated. * as that will result in exceptions since the labels cannot be calculated.
* Do not create dummy labels to fix the issue, since the code addresses will * Do not create dummy labels to fix the issue, since the code addresses will
* be messed up and results in broken Dalvik bytecode. * be messed up and results in broken Dalvik bytecode.
* FIXME: Fix the above issue. When this is fixed, add the proper conversions in [InstructionConverter].
*/ */
fun compileMethodInstructions(instructions: String): List<BuilderInstruction> { fun compileMethodInstructions(instructions: String): List<BuilderInstruction> {
val input = METHOD_TEMPLATE.format(instructions) val input = METHOD_TEMPLATE.format(instructions)