mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 15:24:43 +02:00
8006758: LinkResolver assertion (caused by @Contended changes)
Treat anonymous classes as privileged code to restore the special handling for @Compiled during class file parsing Reviewed-by: jrose, coleenp, kvn, dholmes
This commit is contained in:
parent
8915295560
commit
ae1a2f5e3c
1 changed files with 3 additions and 5 deletions
|
@ -1802,11 +1802,9 @@ ClassFileParser::AnnotationCollector::ID
|
||||||
ClassFileParser::AnnotationCollector::annotation_index(ClassLoaderData* loader_data,
|
ClassFileParser::AnnotationCollector::annotation_index(ClassLoaderData* loader_data,
|
||||||
Symbol* name) {
|
Symbol* name) {
|
||||||
vmSymbols::SID sid = vmSymbols::find_sid(name);
|
vmSymbols::SID sid = vmSymbols::find_sid(name);
|
||||||
bool privileged = false;
|
// Privileged code can use all annotations. Other code silently drops some.
|
||||||
if (loader_data->is_the_null_class_loader_data()) {
|
bool privileged = loader_data->is_the_null_class_loader_data() ||
|
||||||
// Privileged code can use all annotations. Other code silently drops some.
|
loader_data->is_anonymous();
|
||||||
privileged = true;
|
|
||||||
}
|
|
||||||
switch (sid) {
|
switch (sid) {
|
||||||
case vmSymbols::VM_SYMBOL_ENUM_NAME(java_lang_invoke_ForceInline_signature):
|
case vmSymbols::VM_SYMBOL_ENUM_NAME(java_lang_invoke_ForceInline_signature):
|
||||||
if (_location != _in_method) break; // only allow for methods
|
if (_location != _in_method) break; // only allow for methods
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue