2791 |
2791 |
2792 guarantee_property(_max_bootstrap_specifier_index < attribute_array_length, |
2792 guarantee_property(_max_bootstrap_specifier_index < attribute_array_length, |
2793 "Short length on BootstrapMethods in class file %s", |
2793 "Short length on BootstrapMethods in class file %s", |
2794 CHECK); |
2794 CHECK); |
2795 |
2795 |
|
2796 guarantee_property(attribute_byte_length >= sizeof(u2), |
|
2797 "Invalid BootstrapMethods attribute length %u in class file %s", |
|
2798 attribute_byte_length, |
|
2799 CHECK); |
|
2800 |
2796 // The attribute contains a counted array of counted tuples of shorts, |
2801 // The attribute contains a counted array of counted tuples of shorts, |
2797 // represending bootstrap specifiers: |
2802 // represending bootstrap specifiers: |
2798 // length*{bootstrap_method_index, argument_count*{argument_index}} |
2803 // length*{bootstrap_method_index, argument_count*{argument_index}} |
2799 int operand_count = (attribute_byte_length - sizeof(u2)) / sizeof(u2); |
2804 int operand_count = (attribute_byte_length - sizeof(u2)) / sizeof(u2); |
2800 // operand_count = number of shorts in attr, except for leading length |
2805 // operand_count = number of shorts in attr, except for leading length |