mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-20 19:14:38 +02:00
7004698: javap does not output CharacterRangeTable attributes correctly
Reviewed-by: mcimadamore
This commit is contained in:
parent
8e9c506c6c
commit
b9f90baa59
2 changed files with 107 additions and 10 deletions
|
@ -158,17 +158,15 @@ public class AttributeWriter extends BasicWriter
|
|||
indent(+1);
|
||||
for (int i = 0; i < attr.character_range_table.length; i++) {
|
||||
CharacterRangeTable_attribute.Entry e = attr.character_range_table[i];
|
||||
print(" " + e.start_pc + ", " +
|
||||
e.end_pc + ", " +
|
||||
Integer.toHexString(e.character_range_start) + ", " +
|
||||
Integer.toHexString(e.character_range_end) + ", " +
|
||||
Integer.toHexString(e.flags));
|
||||
print(String.format(" %2d, %2d, %6x, %6x, %4x",
|
||||
e.start_pc, e.end_pc,
|
||||
e.character_range_start, e.character_range_end,
|
||||
e.flags));
|
||||
tab();
|
||||
print("// ");
|
||||
print(e.start_pc + ", " +
|
||||
e.end_pc + ", " +
|
||||
(e.character_range_start >> 10) + ":" + (e.character_range_start & 0x3ff) + ", " +
|
||||
(e.character_range_end >> 10) + ":" + (e.character_range_end & 0x3ff));
|
||||
print(String.format("// %2d, %2d, %4d:%02d, %4d:%02d",
|
||||
e.start_pc, e.end_pc,
|
||||
(e.character_range_start >> 10), (e.character_range_start & 0x3ff),
|
||||
(e.character_range_end >> 10), (e.character_range_end & 0x3ff)));
|
||||
if ((e.flags & CharacterRangeTable_attribute.CRT_STATEMENT) != 0)
|
||||
print(", statement");
|
||||
if ((e.flags & CharacterRangeTable_attribute.CRT_BLOCK) != 0)
|
||||
|
@ -187,6 +185,7 @@ public class AttributeWriter extends BasicWriter
|
|||
print(", branch-true");
|
||||
if ((e.flags & CharacterRangeTable_attribute.CRT_BRANCH_FALSE) != 0)
|
||||
print(", branch-false");
|
||||
println();
|
||||
}
|
||||
indent(-1);
|
||||
return null;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue