< prev index next >

src/jdk.compiler/share/classes/com/sun/tools/javac/code/Source.java

Print this page

245         SWITCH_MULTIPLE_CASE_LABELS(JDK14, Fragments.FeatureMultipleCaseLabels, DiagKind.PLURAL),
246         SWITCH_RULE(JDK14, Fragments.FeatureSwitchRules, DiagKind.PLURAL),
247         SWITCH_EXPRESSION(JDK14, Fragments.FeatureSwitchExpressions, DiagKind.PLURAL),
248         NO_TARGET_ANNOTATION_APPLICABILITY(JDK14),
249         TEXT_BLOCKS(JDK15, Fragments.FeatureTextBlocks, DiagKind.PLURAL),
250         PATTERN_MATCHING_IN_INSTANCEOF(JDK16, Fragments.FeaturePatternMatchingInstanceof, DiagKind.NORMAL),
251         REIFIABLE_TYPES_INSTANCEOF(JDK16, Fragments.FeatureReifiableTypesInstanceof, DiagKind.PLURAL),
252         RECORDS(JDK16, Fragments.FeatureRecords, DiagKind.PLURAL),
253         SEALED_CLASSES(JDK17, Fragments.FeatureSealedClasses, DiagKind.PLURAL),
254         CASE_NULL(JDK21, Fragments.FeatureCaseNull, DiagKind.NORMAL),
255         PATTERN_SWITCH(JDK21, Fragments.FeaturePatternSwitch, DiagKind.PLURAL),
256         REDUNDANT_STRICTFP(JDK17),
257         UNCONDITIONAL_PATTERN_IN_INSTANCEOF(JDK21, Fragments.FeatureUnconditionalPatternsInInstanceof, DiagKind.PLURAL),
258         RECORD_PATTERNS(JDK21, Fragments.FeatureDeconstructionPatterns, DiagKind.PLURAL),
259         IMPLICIT_CLASSES(JDK21, Fragments.FeatureImplicitClasses, DiagKind.PLURAL),
260         WARN_ON_ILLEGAL_UTF8(MIN, JDK21),
261         UNNAMED_VARIABLES(JDK22, Fragments.FeatureUnnamedVariables, DiagKind.PLURAL),
262         PRIMITIVE_PATTERNS(JDK23, Fragments.FeaturePrimitivePatterns, DiagKind.PLURAL),
263         FLEXIBLE_CONSTRUCTORS(JDK22, Fragments.FeatureFlexibleConstructors, DiagKind.NORMAL),
264         MODULE_IMPORTS(JDK23, Fragments.FeatureModuleImports, DiagKind.PLURAL),

265         ;
266 
267         enum DiagKind {
268             NORMAL,
269             PLURAL;
270         }
271 
272         private final Source minLevel;
273         private final Source maxLevel;
274         private final Fragment optFragment;
275         private final DiagKind optKind;
276 
277         Feature(Source minLevel) {
278             this(minLevel, null, null);
279         }
280 
281         Feature(Source minLevel, Fragment optFragment, DiagKind optKind) {
282             this(minLevel, MAX, optFragment, optKind);
283         }
284 

245         SWITCH_MULTIPLE_CASE_LABELS(JDK14, Fragments.FeatureMultipleCaseLabels, DiagKind.PLURAL),
246         SWITCH_RULE(JDK14, Fragments.FeatureSwitchRules, DiagKind.PLURAL),
247         SWITCH_EXPRESSION(JDK14, Fragments.FeatureSwitchExpressions, DiagKind.PLURAL),
248         NO_TARGET_ANNOTATION_APPLICABILITY(JDK14),
249         TEXT_BLOCKS(JDK15, Fragments.FeatureTextBlocks, DiagKind.PLURAL),
250         PATTERN_MATCHING_IN_INSTANCEOF(JDK16, Fragments.FeaturePatternMatchingInstanceof, DiagKind.NORMAL),
251         REIFIABLE_TYPES_INSTANCEOF(JDK16, Fragments.FeatureReifiableTypesInstanceof, DiagKind.PLURAL),
252         RECORDS(JDK16, Fragments.FeatureRecords, DiagKind.PLURAL),
253         SEALED_CLASSES(JDK17, Fragments.FeatureSealedClasses, DiagKind.PLURAL),
254         CASE_NULL(JDK21, Fragments.FeatureCaseNull, DiagKind.NORMAL),
255         PATTERN_SWITCH(JDK21, Fragments.FeaturePatternSwitch, DiagKind.PLURAL),
256         REDUNDANT_STRICTFP(JDK17),
257         UNCONDITIONAL_PATTERN_IN_INSTANCEOF(JDK21, Fragments.FeatureUnconditionalPatternsInInstanceof, DiagKind.PLURAL),
258         RECORD_PATTERNS(JDK21, Fragments.FeatureDeconstructionPatterns, DiagKind.PLURAL),
259         IMPLICIT_CLASSES(JDK21, Fragments.FeatureImplicitClasses, DiagKind.PLURAL),
260         WARN_ON_ILLEGAL_UTF8(MIN, JDK21),
261         UNNAMED_VARIABLES(JDK22, Fragments.FeatureUnnamedVariables, DiagKind.PLURAL),
262         PRIMITIVE_PATTERNS(JDK23, Fragments.FeaturePrimitivePatterns, DiagKind.PLURAL),
263         FLEXIBLE_CONSTRUCTORS(JDK22, Fragments.FeatureFlexibleConstructors, DiagKind.NORMAL),
264         MODULE_IMPORTS(JDK23, Fragments.FeatureModuleImports, DiagKind.PLURAL),
265         REFLECT_METHODS(JDK22, Fragments.FeatureReflectMethods, DiagKind.NORMAL),
266         ;
267 
268         enum DiagKind {
269             NORMAL,
270             PLURAL;
271         }
272 
273         private final Source minLevel;
274         private final Source maxLevel;
275         private final Fragment optFragment;
276         private final DiagKind optKind;
277 
278         Feature(Source minLevel) {
279             this(minLevel, null, null);
280         }
281 
282         Feature(Source minLevel, Fragment optFragment, DiagKind optKind) {
283             this(minLevel, MAX, optFragment, optKind);
284         }
285 
< prev index next >