< prev index next >

src/share/vm/classfile/packageEntry.cpp

Print this page

        

*** 99,118 **** if (m == NULL) { // NULL indicates the package is being unqualifiedly exported. Clean up // the qualified list at the next safepoint. set_unqual_exported(); - } else { // Add the exported module add_qexport(m); } } // Set the package as exported to all unnamed modules unless the package is // already unqualifiedly exported. void PackageEntry::set_is_exported_allUnnamed() { MutexLocker m1(Module_lock); if (!is_unqual_exported()) { _export_flags = PKG_EXP_ALLUNNAMED; } } --- 99,122 ---- if (m == NULL) { // NULL indicates the package is being unqualifiedly exported. Clean up // the qualified list at the next safepoint. set_unqual_exported(); } else { // Add the exported module add_qexport(m); } } // Set the package as exported to all unnamed modules unless the package is // already unqualifiedly exported. void PackageEntry::set_is_exported_allUnnamed() { + if (module()->is_open()) { + // No-op for open modules since all packages are unqualifiedly exported + return; + } + MutexLocker m1(Module_lock); if (!is_unqual_exported()) { _export_flags = PKG_EXP_ALLUNNAMED; } }
*** 206,220 **** TRACE_INIT_ID(entry); // Initialize fields specific to a PackageEntry entry->init(); entry->name()->increment_refcount(); - if (!module->is_named()) { - // Set the exported state to true because all packages - // within the unnamed module are unqualifiedly exported - entry->set_unqual_exported(); - } entry->set_module(module); return entry; } void PackageEntryTable::add_entry(int index, PackageEntry* new_entry) { --- 210,219 ----
< prev index next >