mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-04-20 05:21:29 +07:00
java 18 is generally available
GitOrigin-RevId: 6da5af5f9d23adf4aacfc5752765103bb6732a8a
This commit is contained in:
committed by
intellij-monorepo-bot
parent
e3bed0914c
commit
0039037092
@@ -46,7 +46,7 @@ public enum LanguageLevel {
|
||||
/**
|
||||
* Should point to the last released JDK.
|
||||
*/
|
||||
public static final LanguageLevel HIGHEST = JDK_17;
|
||||
public static final LanguageLevel HIGHEST = JDK_18;
|
||||
public static final Key<LanguageLevel> KEY = Key.create("LANGUAGE_LEVEL");
|
||||
|
||||
private final Supplier<@Nls String> myPresentableText;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/**
|
||||
* A simple program.
|
||||
* {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :}
|
||||
* {@snippet :}
|
||||
*/
|
||||
class A {
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
/**
|
||||
* A simple program.
|
||||
* {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
* {@snippet :
|
||||
*
|
||||
* }
|
||||
*/
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/** {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
/** {@snippet :
|
||||
* Body
|
||||
* }
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/**
|
||||
* {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> lang=JAVA :
|
||||
* {@snippet lang=JAVA :
|
||||
* public class ShowOptional {
|
||||
* void show(Optional<String> v) {
|
||||
* // @start region="example"
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/** {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
/** {@snippet :
|
||||
* Optional<Integer> v = null;
|
||||
* if (v.isPresent()) {
|
||||
* System.out.println("v: " + v.get());
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/** {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
/** {@snippet :
|
||||
* FileInputStream is = new FileInputStream("hello.world");
|
||||
* int r = is.read();
|
||||
* }
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/** {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
/** {@snippet :
|
||||
* void f() {}
|
||||
* }
|
||||
*/
|
||||
|
||||
@@ -2,7 +2,7 @@ class A {
|
||||
|
||||
/**
|
||||
* A simple program.
|
||||
* {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
* {@snippet :
|
||||
* class HelloWorld {
|
||||
* void
|
||||
* f(
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/**
|
||||
* A simple program.
|
||||
* {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :}
|
||||
* {@snippet :}
|
||||
*/
|
||||
class A {
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
/**
|
||||
* A simple program.
|
||||
* {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
* {@snippet :
|
||||
*
|
||||
* }
|
||||
*/
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/** {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
/** {@snippet :
|
||||
* Body
|
||||
* }
|
||||
*/
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/**
|
||||
* {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> lang=JAVA :
|
||||
* {@snippet lang=JAVA :
|
||||
* public class ShowOptional {
|
||||
* void show(Optional<String> v) {
|
||||
* // @start region="example"
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/** {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
/** {@snippet :
|
||||
* Optional<Integer> v = null;
|
||||
* if (v.isPresent()) {
|
||||
* System.out.println("v: " + v.get());
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/** {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
/** {@snippet :
|
||||
* FileInputStream is = new FileInputStream("hello.world");
|
||||
* int r = is.read();
|
||||
* }
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/** {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
/** {@snippet :
|
||||
* void f() {}
|
||||
* }
|
||||
*/
|
||||
|
||||
@@ -160,7 +160,7 @@ class JavadocCompletionTest extends LightFixtureCompletionTestCase {
|
||||
|
||||
void testInlineLookup() {
|
||||
configureByFile("InlineTagName.java")
|
||||
assertStringItems("code", "docRoot", "index", "inheritDoc", "link", "linkplain", "literal", "summary", "systemProperty", "value")
|
||||
assertStringItems("code", "docRoot", "index", "inheritDoc", "link", "linkplain", "literal", "snippet", "summary", "systemProperty", "value")
|
||||
}
|
||||
|
||||
@NeedsIndex.ForStandardLibrary
|
||||
@@ -775,7 +775,7 @@ interface Bar<T> extends Foo<T> {
|
||||
void "test tags at top level inline"() {
|
||||
myFixture.configureByText 'a.java', "interface Foo { /** Hello <caret> */void foo(int a); }"
|
||||
myFixture.completeBasic()
|
||||
assert myFixture.lookupElementStrings == ['{@code}', '{@docRoot}', '{@index}', '{@inheritDoc}', '{@linkplain}', '{@link}', '{@literal}', '{@summary}', '{@systemProperty}', '{@value}']
|
||||
assert myFixture.lookupElementStrings == ['{@code}', '{@docRoot}', '{@index}', '{@inheritDoc}', '{@linkplain}', '{@link}', '{@literal}', '{@snippet}', '{@summary}', '{@systemProperty}', '{@value}']
|
||||
def element = myFixture.lookupElements[5]
|
||||
assert element.lookupString == "{@link}"
|
||||
selectItem(element)
|
||||
@@ -785,7 +785,7 @@ interface Bar<T> extends Foo<T> {
|
||||
void "test tags after return"() {
|
||||
myFixture.configureByText 'a.java', "interface Foo { /** @return <caret> */int foo(int a); }"
|
||||
myFixture.completeBasic()
|
||||
assert myFixture.lookupElementStrings == ['{@code}', '{@docRoot}', '{@index}', '{@inheritDoc}', '{@linkplain}', '{@link}', '{@literal}', '{@return}', '{@summary}', '{@systemProperty}', '{@value}']
|
||||
assert myFixture.lookupElementStrings == ['{@code}', '{@docRoot}', '{@index}', '{@inheritDoc}', '{@linkplain}', '{@link}', '{@literal}', '{@return}', '{@snippet}', '{@summary}', '{@systemProperty}', '{@value}']
|
||||
def element = myFixture.lookupElements[5]
|
||||
assert element.lookupString == "{@link}"
|
||||
selectItem(element)
|
||||
@@ -795,7 +795,7 @@ interface Bar<T> extends Foo<T> {
|
||||
void "test tags at top level inline in brace"() {
|
||||
myFixture.configureByText 'a.java', "interface Foo { /** Hello {<caret>} */void foo(int a); }"
|
||||
myFixture.completeBasic()
|
||||
assert myFixture.lookupElementStrings == ['@code', '@docRoot', '@index', '@inheritDoc', '@link', '@linkplain', '@literal', '@summary', '@systemProperty', '@value']
|
||||
assert myFixture.lookupElementStrings == ['@code', '@docRoot', '@index', '@inheritDoc', '@link', '@linkplain', '@literal', '@snippet', '@summary', '@systemProperty', '@value']
|
||||
def element = myFixture.lookupElements[4]
|
||||
assert element.lookupString == "@link"
|
||||
selectItem(element)
|
||||
|
||||
@@ -26,7 +26,7 @@ public enum LanguageLevel {
|
||||
JDK_18(18), JDK_18_PREVIEW(18),
|
||||
JDK_X(19);
|
||||
|
||||
public static final LanguageLevel HIGHEST = JDK_17;
|
||||
public static final LanguageLevel HIGHEST = JDK_18;
|
||||
|
||||
private final JavaVersion myVersion;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user