Navigation to invoke() from {}

Example:

foo <caret>{}
This commit is contained in:
Andrey Breslav
2013-08-28 15:26:47 +04:00
parent a53986e1d6
commit 87293a8831
12 changed files with 179 additions and 19 deletions
@@ -20,7 +20,7 @@ import com.intellij.lang.ASTNode;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import org.jetbrains.jet.JetNodeTypes;
import org.jetbrains.jet.lexer.JetToken;
import org.jetbrains.jet.lexer.JetTokens;
import java.util.List;
@@ -65,4 +65,14 @@ public class JetFunctionLiteralExpression extends JetExpressionImpl {
public JetElement asElement() {
return this;
}
@NotNull
public ASTNode getLeftCurlyBrace() {
return getFunctionLiteral().getNode().findChildByType(JetTokens.LBRACE);
}
@Nullable
public ASTNode getRightCurlyBrace() {
return getFunctionLiteral().getNode().findChildByType(JetTokens.RBRACE);
}
}