mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-04-17 20:11:25 +07:00
[javadoc] IDEA-285556 Support language injection into snippet
Add an enclosing class for snippets in order not to make users define a class in a snippet code to eliminate syntax errors when the code consists of a set of instructions GitOrigin-RevId: c6f52f94d51fdc6393c8a9fdc0ddb615e8d37b17
This commit is contained in:
committed by
intellij-monorepo-bot
parent
f628190d6d
commit
34ec0bb7c9
@@ -1,5 +1,5 @@
|
||||
/** {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
* <error descr="'class' or 'interface' expected">Body</error>
|
||||
* Body<EOLError descr="Identifier expected"></EOLError>
|
||||
* }
|
||||
*/
|
||||
class A {
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
/** {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
* {
|
||||
* Optional<Integer> v = null;
|
||||
* if (v.isPresent()) {
|
||||
* System.out.println("v: " + v.get());
|
||||
* }
|
||||
* }
|
||||
* }
|
||||
*/
|
||||
class A {
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
/** {<warning descr="'@snippet' tag is not available at this language level">@snippet</warning> :
|
||||
* void f() {}
|
||||
* }
|
||||
*/
|
||||
class A {
|
||||
}
|
||||
Reference in New Issue
Block a user