diff --git a/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Check.java b/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Check.java index a1519c040db2d..f2bf737287e3d 100644 --- a/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Check.java +++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Check.java @@ -2969,11 +2969,11 @@ void checkAccessFromSerializableElement(final JCTree tree, boolean isLambda) { if (isLambda) { if (belongsToRestrictedPackage(sym)) { log.warning(tree.pos(), - Warnings.AccessToMemberFromSerializableLambda(sym)); + LintWarnings.AccessToMemberFromSerializableLambda(sym)); } } else { log.warning(tree.pos(), - Warnings.AccessToMemberFromSerializableElement(sym)); + LintWarnings.AccessToMemberFromSerializableElement(sym)); } } } diff --git a/src/jdk.compiler/share/classes/com/sun/tools/javac/resources/compiler.properties b/src/jdk.compiler/share/classes/com/sun/tools/javac/resources/compiler.properties index ca9c254cf8665..364441cd7edc0 100644 --- a/src/jdk.compiler/share/classes/com/sun/tools/javac/resources/compiler.properties +++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/resources/compiler.properties @@ -2482,10 +2482,12 @@ compiler.warn.varargs.redundant.trustme.anno=\ Redundant {0} annotation. {1} # 0: symbol +# lint: serial compiler.warn.access.to.member.from.serializable.element=\ access to member {0} from serializable element can be publicly accessible to untrusted code # 0: symbol +# lint: serial compiler.warn.access.to.member.from.serializable.lambda=\ access to member {0} from serializable lambda can be publicly accessible to untrusted code diff --git a/src/jdk.compiler/share/classes/com/sun/tools/javac/util/JCDiagnostic.java b/src/jdk.compiler/share/classes/com/sun/tools/javac/util/JCDiagnostic.java index 3e07751009b4d..92caf7c3f4764 100644 --- a/src/jdk.compiler/share/classes/com/sun/tools/javac/util/JCDiagnostic.java +++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/util/JCDiagnostic.java @@ -593,7 +593,7 @@ public Warning(String prefix, String key, Object... args) { } /** - * Class representing warning diagnostic keys. + * Class representing lint warning diagnostic keys. */ public static final class LintWarning extends Warning { final LintCategory category;