Add intention for converting to block comment and vise versa
So #KT-23137 Fixed
This commit is contained in:
committed by
Mikhail Glukhikh
parent
3351b00870
commit
e58d9c5507
@@ -153,6 +153,10 @@ fun PsiElement.getPrevSiblingIgnoringWhitespaceAndComments(withItself: Boolean =
|
||||
return siblings(withItself = withItself, forward = false).filter { it !is PsiWhiteSpace && it !is PsiComment }.firstOrNull()
|
||||
}
|
||||
|
||||
fun PsiElement.getPrevSiblingIgnoringWhitespace(withItself: Boolean = false): PsiElement? {
|
||||
return siblings(withItself = withItself, forward = false).filter { it !is PsiWhiteSpace }.firstOrNull()
|
||||
}
|
||||
|
||||
inline fun <reified T : PsiElement> T.nextSiblingOfSameType() = PsiTreeUtil.getNextSiblingOfType(this, T::class.java)
|
||||
|
||||
inline fun <reified T : PsiElement> T.prevSiblingOfSameType() = PsiTreeUtil.getPrevSiblingOfType(this, T::class.java)
|
||||
|
||||
Reference in New Issue
Block a user