feat: parametersCount for InlineSmaliCompiler instead of parameters

This commit is contained in:
oSumAtrIX 2022-06-20 02:23:17 +02:00
parent fd690acd61
commit ad6c5c8273
No known key found for this signature in database
GPG key ID: A9B3094ACDB604B4

View file

@ -59,8 +59,8 @@ class InlineSmaliCompiler {
}
}
fun String.toInstructions(parameters: String = "", registers: Int = 1, forStaticMethod: Boolean = true) =
InlineSmaliCompiler.compileMethodInstructions(this, parameters, registers, forStaticMethod)
fun String.toInstructions(parametersCount: Int = 0, registers: Int = 1, forStaticMethod: Boolean = true) =
InlineSmaliCompiler.compileMethodInstructions(this, "I".repeat(parametersCount), registers, forStaticMethod)
fun String.toInstruction(parameters: String = "", registers: Int = 1, forStaticMethod: Boolean = true) =
this.toInstructions(parameters, registers, forStaticMethod).first()
fun String.toInstruction(parametersCount: Int = 0, registers: Int = 1, forStaticMethod: Boolean = true) =
this.toInstructions(parametersCount, registers, forStaticMethod).first()