What’s a difference between “FRAME FULL” and “FRAME APPEND”?
I check 2 ways to use iterators:
int size = 0;
Iterator<String> it = l.iterator();
while (it.hasNext()) {
String s = it.next();
int length = s.length();
size += length;
}
int size = 0;
for (String s : l) {
int length = s.length();
size += length;
}
they both use iterators, but bytecode is a bit different.
The frame type append_frame is used when the operand stack is empty and the current locals are the same as the locals in the previous frame, except that k additional locals are defined. Frame type full_frame is used when all other types are not applicably, it is also less compact one.