Java: JShell should allow creating records (IDEA-353210)

GitOrigin-RevId: b22db66ea43261281c60fc501d8201872cda9dfc
This commit is contained in:
Bas Leijdekkers
2025-01-01 20:00:17 +00:00
committed by intellij-monorepo-bot
parent 0ef89717d7
commit bc58434b41
2 changed files with 5 additions and 1 deletions
@@ -447,6 +447,9 @@ public final class JShellHandler {
else if (subKind == CodeSnippet.SubKind.ENUM_SUBKIND) {
kindLabel = "enum";
}
else if (subKind == CodeSnippet.SubKind.RECORD_SUBKIND) {
kindLabel = "record";
}
else if (subKind == CodeSnippet.SubKind.ANNOTATION_TYPE_SUBKIND) {
kindLabel = "annotation";
}
@@ -1,4 +1,4 @@
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
package com.intellij.execution.jshell.protocol;
import java.io.Serializable;
@@ -67,6 +67,7 @@ public class CodeSnippet implements Serializable {
CLASS_SUBKIND(Kind.TYPE_DECL),
INTERFACE_SUBKIND(Kind.TYPE_DECL),
ENUM_SUBKIND(Kind.TYPE_DECL),
RECORD_SUBKIND(Kind.TYPE_DECL),
ANNOTATION_TYPE_SUBKIND(Kind.TYPE_DECL),
METHOD_SUBKIND(Kind.METHOD),
VAR_DECLARATION_SUBKIND(Kind.VAR),