mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Unneeded instance creation eliminated
This commit is contained in:
@@ -20,6 +20,6 @@ package com.intellij.lexer;
|
||||
*/
|
||||
public class JavaDocLexer extends DocCommentLexer {
|
||||
public JavaDocLexer(final boolean isJdk15Enabled) {
|
||||
super(new JavaDocTokenTypes(), isJdk15Enabled);
|
||||
super(JavaDocTokenTypes.INSTANCE, isJdk15Enabled);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,6 +22,10 @@ import com.intellij.psi.tree.IElementType;
|
||||
* @author yole
|
||||
*/
|
||||
public class JavaDocTokenTypes implements DocCommentTokenTypes {
|
||||
public static final DocCommentTokenTypes INSTANCE = new JavaDocTokenTypes();
|
||||
|
||||
private JavaDocTokenTypes() { }
|
||||
|
||||
public IElementType commentStart() {
|
||||
return JavaDocTokenType.DOC_COMMENT_START;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user