hello, I'm trying to change the name of a REFERENC...
# intellij-plugins
hello, I'm trying to change the name of a REFERENCE_EXPRESSION. I'm trying to do that by replacing the PsiElement (IDENTIFIER) child of it. Sadly in the
fun visitReferenceExpression(expression: KtReferenceExpression)
method the expression is missing the identifier child. The other problem I have is that when I try the resolve the declaration reference, I always get null and the references list is empty, even though the Psi Viewer plugin shows that it shouldn't be. Is it possible to modify the PSI from a visitor?
To make things more clear - I'm trying to perform a renaming action, but I don't want to search for all DotQualifiedExpressions, Property declarations that use that reference, etc., so I'm trying to modify the reference expression directly, so I don't have to care about its parent. This is as part of a compiler plugin, not an IDE one
Okay... I just figured that I actually can't modify the PSI in the compiler...