diff --git a/src/hotspot/share/runtime/reflection.cpp b/src/hotspot/share/runtime/reflection.cpp index 0a80359cfe3..0eaa5668250 100644 --- a/src/hotspot/share/runtime/reflection.cpp +++ b/src/hotspot/share/runtime/reflection.cpp @@ -457,12 +457,6 @@ Reflection::VerifyClassAccessResults Reflection::verify_class_access( // module boundaries if (new_class->is_public()) { - // Ignore modules for -Xshare:dump because we do not have any package - // or module information for modules other than java.base. - if (CDSConfig::is_dumping_static_archive()) { - return ACCESS_OK; - } - // Find the module entry for current_class, the accessor ModuleEntry* module_from = current_class->module(); // Find the module entry for new_class, the accessee