Implement "Safe Delete" refactoring for named functions

Conflicts:
	idea/src/org/jetbrains/jet/plugin/refactoring/safeDelete/KotlinSafeDeleteProcessor.java
This commit is contained in:
Alexey Sedunov
2013-07-12 18:18:46 +04:00
parent 6658564bdd
commit cd6b6e4934
71 changed files with 1442 additions and 43 deletions
@@ -18,6 +18,7 @@ package org.jetbrains.jet.lang.psi;
import com.google.common.collect.Lists;
import com.intellij.lang.ASTNode;
import com.intellij.psi.PsiElement;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import org.jetbrains.jet.JetNodeTypes;
@@ -62,6 +63,11 @@ public class JetModifierList extends JetElementImpl {
return getModifierNode(token) != null;
}
@Nullable
public PsiElement getModifier(JetToken token) {
return findChildByType(token);
}
@Nullable
public ASTNode getModifierNode(JetToken token) {
ASTNode node = getNode().getFirstChildNode();
@@ -71,4 +77,6 @@ public class JetModifierList extends JetElementImpl {
}
return null;
}
}