Skip to main content

This CGIT instance is deprecated, and repositories have been moved to Gitlab or Github. See the repository descriptions for specific locations.

aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSarika Sinha2020-07-01 14:25:15 +0000
committerSarika Sinha2020-07-01 14:25:15 +0000
commit46ae60fe5559797034ba298c247faac45121ed55 (patch)
treee34d6651b26f4141e32b73ba091d2e9729f2dfa7
parent075d1c9bdd745e23e18c6b661be35e2620049c5e (diff)
downloadeclipse.jdt.core-Y20200701-1200.tar.gz
eclipse.jdt.core-Y20200701-1200.tar.xz
eclipse.jdt.core-Y20200701-1200.zip
Bug 564841 - IllegalArgumentException in content assist for seal typesY20200701-1200
-rw-r--r--org.eclipse.jdt.core/dom/org/eclipse/jdt/core/dom/ASTConverter.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/org.eclipse.jdt.core/dom/org/eclipse/jdt/core/dom/ASTConverter.java b/org.eclipse.jdt.core/dom/org/eclipse/jdt/core/dom/ASTConverter.java
index d29c7f561a..de6d32b6f6 100644
--- a/org.eclipse.jdt.core/dom/org/eclipse/jdt/core/dom/ASTConverter.java
+++ b/org.eclipse.jdt.core/dom/org/eclipse/jdt/core/dom/ASTConverter.java
@@ -3303,7 +3303,10 @@ class ASTConverter {
if (permittedTypes != null) {
if (DOMASTUtil.isFeatureSupportedinAST(this.ast, Modifier.SEALED)) {
for (int index = 0, length = permittedTypes.length; index < length; index++) {
- typeDecl.permittedTypes().add(convertType(permittedTypes[index]));
+ Type convertType = convertType(permittedTypes[index]);
+ if (convertType != null) {
+ typeDecl.permittedTypes().add(convertType);
+ }
}
}
}

Back to the top