Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJay Arthanareeswaran2019-01-24 10:36:29 +0000
committerJay Arthanareeswaran2019-01-24 10:36:29 +0000
commitbf1f831ccfe73711e3249e279ab200256aa22edf (patch)
tree81c7faec842e01ef8e226ceaea9d8d18ee1440de
parent21f33bc19ab57e7115c92b70f11aeab28e12da2c (diff)
downloadeclipse.jdt.core-bf1f831ccfe73711e3249e279ab200256aa22edf.tar.gz
eclipse.jdt.core-bf1f831ccfe73711e3249e279ab200256aa22edf.tar.xz
eclipse.jdt.core-bf1f831ccfe73711e3249e279ab200256aa22edf.zip
Bug 542654 - [12] API in JavaCore to set --enable-preview
New problem category for compliance related options Change-Id: I81d61a8db7d70af4265f3a752aadbae4892ba0f2 Signed-off-by: Jay Arthanareeswaran <jarthana@in.ibm.com>
-rw-r--r--org.eclipse.jdt.core/compiler/org/eclipse/jdt/core/compiler/IProblem.java10
-rw-r--r--org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/impl/CompilerOptions.java2
2 files changed, 8 insertions, 4 deletions
diff --git a/org.eclipse.jdt.core/compiler/org/eclipse/jdt/core/compiler/IProblem.java b/org.eclipse.jdt.core/compiler/org/eclipse/jdt/core/compiler/IProblem.java
index 10870eee09..fa7099dd9b 100644
--- a/org.eclipse.jdt.core/compiler/org/eclipse/jdt/core/compiler/IProblem.java
+++ b/org.eclipse.jdt.core/compiler/org/eclipse/jdt/core/compiler/IProblem.java
@@ -377,11 +377,13 @@ void setSourceStart(int sourceStart);
int Javadoc = 0x80000000;
/** @since 3.14 */
int ModuleRelated = 0x00800000;
+ /** @since 3.17 BETA_JAVA_12 */
+ int Compliance = 0x00400000;
/**
* Mask to use in order to filter out the category portion of the problem ID.
*/
- int IgnoreCategoriesMask = 0x7FFFFF;
+ int IgnoreCategoriesMask = 0x3FFFFF;
/*
* Below are listed all available problem IDs. Note that this list could be augmented in the future,
@@ -2050,11 +2052,11 @@ void setSourceStart(int sourceStart);
/** @since 3.13 */
int ProblemNotAnalysed = 1102;
/** @since 3.17 BETA_JAVA_12 */
- int PreviewFeatureDisabled = Syntax + 1103;
+ int PreviewFeatureDisabled = Compliance + 1103;
/** @since 3.17 BETA_JAVA_12 */
- int PreviewFeatureUsed = Syntax + 1104;
+ int PreviewFeatureUsed = Compliance + 1104;
/** @since 3.17 BETA_JAVA_12 */
- int PreviewFeatureNotSupported = Syntax + 1105;
+ int PreviewFeatureNotSupported = Compliance + 1105;
/** @since 3.13 */
int UnlikelyCollectionMethodArgumentType = 1200;
diff --git a/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/impl/CompilerOptions.java b/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/impl/CompilerOptions.java
index 6c6e9f2062..4680e20c76 100644
--- a/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/impl/CompilerOptions.java
+++ b/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/impl/CompilerOptions.java
@@ -763,6 +763,8 @@ public class CompilerOptions {
return OPTION_ReportAPILeak;
case UnstableAutoModuleName:
return OPTION_ReportUnstableAutoModuleName;
+ case PreviewFeatureUsed:
+ return OPTION_ReportPreviewFeatures;
}
return null;
}

Back to the top