I mean in Android Studio, when you try to look in Kotlin bytecode, and than press “Decompile”.
For example Kotlin function:
![image](https://us1.discourse-cdn.com/flex019/uploads/kotlinlang/original/2X/1/11a0c79c105b5f3fa3118c742596b3847f7e03c5.png)
And the decompiled java:
What the reason in creating local variables:
boolean var7 = false;
boolean var8 = false;
int var10 = false;
1 Like
I also wondered about it. When you take a look at the bytecode you can also notice that there are some unused values assigned.
These booleans are used by debugger to determine whether we are inside inline function/lambda or not.
6 Likes
Thanks, it is clear now. And as I understand it is wiped out during release compilation.
gildor
5
There is no such thing as release compilation, only if you use some tool to optimize your bytecode, such as Proguard
2 Likes