From bea496bb6bd2479a39518ea0ccc03bc9509b2d55 Mon Sep 17 00:00:00 2001 From: Michael Pfaff Date: Thu, 11 Apr 2024 14:53:55 -0400 Subject: [PATCH] Allow --add-exports with system modules even when --release is specified --- .../share/classes/com/sun/tools/javac/comp/Modules.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Modules.java b/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Modules.java index 6dd4a368f44ed..f9f284a3edfef 100644 --- a/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Modules.java +++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Modules.java @@ -202,7 +202,7 @@ protected Modules(Context context) { allowModules = Feature.MODULES.allowedInSource(source); Options options = Options.instance(context); - allowAccessIntoSystem = options.isUnset(Option.RELEASE); + allowAccessIntoSystem = true; lintOptions = options.isUnset(Option.XLINT_CUSTOM, "-" + LintCategory.OPTIONS.option); multiModuleMode = fileManager.hasLocation(StandardLocation.MODULE_SOURCE_PATH);