junichi11 commented on a change in pull request #2283: URL: https://github.com/apache/netbeans/pull/2283#discussion_r496643705
########## File path: java/java.completion/src/org/netbeans/modules/java/completion/JavaCompletionTask.java ########## @@ -858,13 +905,22 @@ private void insideClass(Env env) throws IOException { addTypes(env, EnumSet.of(INTERFACE, ANNOTATION_TYPE), null); break; case IDENTIFIER: + if (isSealedSupported(env) && TokenUtilities.textEquals(lastNonWhitespaceToken.token().text(),PERMITS_KEYWORD)) { + controller.toPhase(Phase.ELEMENTS_RESOLVED); + env.addToExcludes(controller.getTrees().getElement(path)); + addClassTypes(env, null); + break; + } if (!tu.isAnnotation(cls)) { if (!tu.isEnum(cls)) { addKeyword(env, EXTENDS_KEYWORD, SPACE, false); + if (isSealedSupported(env)) { + addKeyword(env, PERMITS_KEYWORD, SPACE, false); + } } if (!tu.isInterface(cls)) { addKeyword(env, IMPLEMENTS_KEYWORD, SPACE, false); - } + } Review comment: Please revert. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: notifications-unsubscr...@netbeans.apache.org For additional commands, e-mail: notifications-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists