Skip to content

Commit 6ce7b13

Browse files
Clarifies language in documentation.
1 parent c0c1029 commit 6ce7b13

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

jbmc/src/java_bytecode/java_bytecode_parser.cpp

+6-4
Original file line numberDiff line numberDiff line change
@@ -1581,19 +1581,19 @@ void java_bytecode_parsert::relement_value_pair(
15811581
/// Corresponds to the element_value structure
15821582
/// Described in Java 8 specification 4.7.6
15831583
/// https://docs.oracle.com/javase/specs/jvms/se8/html/jvms-4.html#jvms-4.7.6
1584-
/// Parses the bytes of the InnerClasses attribute for the current parsed class,
1585-
/// which contains any array of information about inner classes. We are
1584+
/// Parses the InnerClasses attribute for the current parsed class,
1585+
/// which contains an array of information about its inner classes. We are
15861586
/// interested in getting information only for inner classes, which is
15871587
/// determined by checking if the parsed class matches any of the inner classes
15881588
/// in its inner class array. If the parsed class is not an inner class, then it
15891589
/// is ignored. When a parsed class is an inner class, the accessibility
15901590
/// information for the parsed class is overwritten, and the parsed class is
1591-
/// marked as an inner class. Note that is outer_class_info_index == 0, the
1592-
/// inner class is an anonymous or local class, and is treated as private.
1591+
/// marked as an inner class.
15931592
void java_bytecode_parsert::rinner_classes_attribute(
15941593
classt &parsed_class,
15951594
const u4 &attribute_length)
15961595
{
1596+
std::string name = parsed_class.name.c_str();
15971597
u2 number_of_classes = read_u2();
15981598
u4 number_of_bytes_to_be_read = number_of_classes * 8 + 2;
15991599
INVARIANT(
@@ -1634,6 +1634,8 @@ void java_bytecode_parsert::rinner_classes_attribute(
16341634
remove_separator_char(inner_class_info_name, '/');
16351635
if(!parsed_class.is_inner_class)
16361636
continue;
1637+
// Note that if outer_class_info_index == 0, the inner class is an anonymous
1638+
// or local class, and is treated as private.
16371639
if(outer_class_info_index == 0)
16381640
{
16391641
// This is a marker for an anonymous or local class

0 commit comments

Comments
 (0)