diff --git a/src/main/kotlin/me/mattco/serenityos/idl/utils.kt b/src/main/kotlin/me/mattco/serenityos/common/psiUtils.kt similarity index 98% rename from src/main/kotlin/me/mattco/serenityos/idl/utils.kt rename to src/main/kotlin/me/mattco/serenityos/common/psiUtils.kt index 2320c01..97aba91 100644 --- a/src/main/kotlin/me/mattco/serenityos/idl/utils.kt +++ b/src/main/kotlin/me/mattco/serenityos/common/psiUtils.kt @@ -1,4 +1,4 @@ -package me.mattco.serenityos.idl +package me.mattco.serenityos.common import com.intellij.psi.PsiElement import com.intellij.psi.PsiWhiteSpace diff --git a/src/main/kotlin/me/mattco/serenityos/idl/IDLResolver.kt b/src/main/kotlin/me/mattco/serenityos/idl/IDLResolver.kt index 2f546ec..2f9ac19 100644 --- a/src/main/kotlin/me/mattco/serenityos/idl/IDLResolver.kt +++ b/src/main/kotlin/me/mattco/serenityos/idl/IDLResolver.kt @@ -2,6 +2,7 @@ package me.mattco.serenityos.idl import com.intellij.psi.PsiElement import com.intellij.psi.util.descendantsOfType +import me.mattco.serenityos.common.findChildrenOfType import me.mattco.serenityos.idl.psi.IDLDeclaration import me.mattco.serenityos.idl.psi.api.IDLImportStatement import me.mattco.serenityos.idl.psi.mixins.resolveFile diff --git a/src/main/kotlin/me/mattco/serenityos/idl/annotation/IDLErrorAnnotator.kt b/src/main/kotlin/me/mattco/serenityos/idl/annotation/IDLErrorAnnotator.kt index c26e48a..8bbfb9e 100644 --- a/src/main/kotlin/me/mattco/serenityos/idl/annotation/IDLErrorAnnotator.kt +++ b/src/main/kotlin/me/mattco/serenityos/idl/annotation/IDLErrorAnnotator.kt @@ -5,7 +5,7 @@ import com.intellij.psi.PsiComment import com.intellij.psi.PsiElement import com.intellij.psi.PsiWhiteSpace import me.mattco.serenityos.common.DSLAnnotator -import me.mattco.serenityos.idl.* +import me.mattco.serenityos.common.prevSiblings import me.mattco.serenityos.idl.psi.IDLDeclaration import me.mattco.serenityos.idl.psi.api.IDLCallbackInterface import me.mattco.serenityos.idl.psi.api.IDLExtendedAttributeList diff --git a/src/main/kotlin/me/mattco/serenityos/idl/folding.kt b/src/main/kotlin/me/mattco/serenityos/idl/folding.kt index 3959379..133bd56 100644 --- a/src/main/kotlin/me/mattco/serenityos/idl/folding.kt +++ b/src/main/kotlin/me/mattco/serenityos/idl/folding.kt @@ -9,6 +9,8 @@ import com.intellij.psi.PsiElement import com.intellij.psi.util.PsiTreeUtil import com.intellij.refactoring.suggested.endOffset import com.intellij.refactoring.suggested.startOffset +import me.mattco.serenityos.common.nextSiblingOfType +import me.mattco.serenityos.common.prevSiblingOfType import me.mattco.serenityos.idl.psi.IDLPsiElement import me.mattco.serenityos.idl.psi.api.* diff --git a/src/main/kotlin/me/mattco/serenityos/idl/project/IDLProjectServiceImpl.kt b/src/main/kotlin/me/mattco/serenityos/idl/project/IDLProjectServiceImpl.kt index 34edb20..788de03 100644 --- a/src/main/kotlin/me/mattco/serenityos/idl/project/IDLProjectServiceImpl.kt +++ b/src/main/kotlin/me/mattco/serenityos/idl/project/IDLProjectServiceImpl.kt @@ -4,7 +4,6 @@ import com.intellij.openapi.project.DumbService import com.intellij.openapi.project.Project import com.intellij.openapi.vfs.VirtualFile import com.intellij.openapi.vfs.toNioPathOrNull -import com.intellij.psi.PsiElement import com.intellij.psi.PsiManager import com.intellij.psi.search.FilenameIndex import com.intellij.psi.search.GlobalSearchScopes @@ -15,7 +14,7 @@ import com.jetbrains.cidr.lang.psi.OCCppNamespace import com.jetbrains.cidr.lang.psi.OCElement import com.jetbrains.cidr.lang.psi.OCFile import com.jetbrains.cidr.lang.psi.OCStructLike -import me.mattco.serenityos.idl.descendentsOfType +import me.mattco.serenityos.common.descendentsOfType import me.mattco.serenityos.idl.IDLFile import me.mattco.serenityos.idl.IDLResolver import me.mattco.serenityos.idl.psi.IDLDeclaration diff --git a/src/main/kotlin/me/mattco/serenityos/idl/psi/IDLPsiFactory.kt b/src/main/kotlin/me/mattco/serenityos/idl/psi/IDLPsiFactory.kt index b193e77..8bc1810 100644 --- a/src/main/kotlin/me/mattco/serenityos/idl/psi/IDLPsiFactory.kt +++ b/src/main/kotlin/me/mattco/serenityos/idl/psi/IDLPsiFactory.kt @@ -3,7 +3,7 @@ package me.mattco.serenityos.idl.psi import com.intellij.openapi.project.Project import com.intellij.psi.PsiElement import com.intellij.psi.PsiFileFactory -import me.mattco.serenityos.idl.descendantOfType +import me.mattco.serenityos.common.descendantOfType import me.mattco.serenityos.idl.IDLFile import me.mattco.serenityos.idl.IDLFileType import me.mattco.serenityos.idl.psi.api.IDLNamespace diff --git a/src/main/kotlin/me/mattco/serenityos/ipc/IPCSyntaxAnnotator.kt b/src/main/kotlin/me/mattco/serenityos/ipc/IPCSyntaxAnnotator.kt index 452c181..d8b1698 100644 --- a/src/main/kotlin/me/mattco/serenityos/ipc/IPCSyntaxAnnotator.kt +++ b/src/main/kotlin/me/mattco/serenityos/ipc/IPCSyntaxAnnotator.kt @@ -3,11 +3,10 @@ package me.mattco.serenityos.ipc import com.intellij.openapi.project.DumbAware import com.intellij.psi.PsiElement import me.mattco.serenityos.common.DSLAnnotator -import me.mattco.serenityos.idl.findChildrenOfType +import me.mattco.serenityos.common.findChildrenOfType import me.mattco.serenityos.ipc.psi.api.IPCAttributeList import me.mattco.serenityos.ipc.psi.api.IPCEndpoint import me.mattco.serenityos.ipc.psi.api.IPCEndpointFunction -import me.mattco.serenityos.ipc.psi.api.IPCInclude import me.mattco.serenityos.ipc.psi.api.IPCIncludePath import me.mattco.serenityos.ipc.psi.api.IPCType diff --git a/src/main/kotlin/me/mattco/serenityos/ipc/project/IPCProjectServiceImpl.kt b/src/main/kotlin/me/mattco/serenityos/ipc/project/IPCProjectServiceImpl.kt index d70034f..08ce41d 100644 --- a/src/main/kotlin/me/mattco/serenityos/ipc/project/IPCProjectServiceImpl.kt +++ b/src/main/kotlin/me/mattco/serenityos/ipc/project/IPCProjectServiceImpl.kt @@ -9,7 +9,7 @@ import com.intellij.psi.search.FileTypeIndex import com.intellij.psi.search.GlobalSearchScopes import com.jetbrains.cidr.lang.psi.OCFile import com.jetbrains.cidr.lang.psi.OCStructLike -import me.mattco.serenityos.idl.findChildOfType +import me.mattco.serenityos.common.findChildOfType import me.mattco.serenityos.ipc.IPCFile import me.mattco.serenityos.ipc.IPCFileType import me.mattco.serenityos.ipc.psi.api.IPCEndpoint diff --git a/src/main/kotlin/me/mattco/serenityos/ipc/psi/IPCPsiFactory.kt b/src/main/kotlin/me/mattco/serenityos/ipc/psi/IPCPsiFactory.kt index 9092f04..911bcef 100644 --- a/src/main/kotlin/me/mattco/serenityos/ipc/psi/IPCPsiFactory.kt +++ b/src/main/kotlin/me/mattco/serenityos/ipc/psi/IPCPsiFactory.kt @@ -3,7 +3,7 @@ package me.mattco.serenityos.ipc.psi import com.intellij.openapi.project.Project import com.intellij.psi.PsiElement import com.intellij.psi.PsiFileFactory -import me.mattco.serenityos.idl.descendantOfType +import me.mattco.serenityos.common.descendantOfType import me.mattco.serenityos.ipc.IPCFile import me.mattco.serenityos.ipc.IPCFileType import me.mattco.serenityos.ipc.psi.api.IPCEndpoint diff --git a/src/main/kotlin/me/mattco/serenityos/ipc/psi/mixins/IPCTypePartMixin.kt b/src/main/kotlin/me/mattco/serenityos/ipc/psi/mixins/IPCTypePartMixin.kt index 74d431c..46f33ab 100644 --- a/src/main/kotlin/me/mattco/serenityos/ipc/psi/mixins/IPCTypePartMixin.kt +++ b/src/main/kotlin/me/mattco/serenityos/ipc/psi/mixins/IPCTypePartMixin.kt @@ -9,8 +9,7 @@ import com.jetbrains.cidr.lang.psi.OCCppNamespace import com.jetbrains.cidr.lang.psi.OCElement import com.jetbrains.cidr.lang.psi.OCStructLike import com.jetbrains.cidr.lang.symbols.OCResolveContext -import me.mattco.serenityos.idl.findChildrenOfType -import me.mattco.serenityos.idl.prevSiblingsOfType +import me.mattco.serenityos.common.findChildrenOfType import me.mattco.serenityos.ipc.IPCFile import me.mattco.serenityos.ipc.psi.IPCNamedElement import me.mattco.serenityos.ipc.psi.api.IPCInclude