LightClassReference - Goto declaration problem
I have an reference to an PsiClass. The reference is correctly
highlighted when pressing Ctrl and moving the mouse over it.
It resolves to an an LightClassReference
(PsiElementFactory.createClassReferenceElement(psiClass)).
But 'Goto declaration' simply does nothing.
What I am doing wrong?
Please sign in to leave a comment.
Hello Sven,
It should resolve to PsiClass instead. No need to resolve to reference
-
Maxim Shafirov
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"
Now as you told that I can't remember why I created this
reference at all :)
BTW: Is this code the correct way to create an PsiClassType?
PsiElementFactory factory=psiClass.getManager().getElementFactory();
type=factory.createType(psiClass);
Maxim Shafirov (JetBrains) schrieb:
>> I have an reference to an PsiClass. The reference is correctly
>> highlighted when pressing Ctrl and moving the mouse over it.
>> It resolves to an an LightClassReference
>> (PsiElementFactory.createClassReferenceElement(psiClass)).
>> But 'Goto declaration' simply does nothing.
>> What I am doing wrong?
>>
Yes, this is perfectly legitimate.
-
Maxim Shafirov
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"
>> Hello Sven,
>>
>> It should resolve to PsiClass instead. No need to resolve to
>> reference
>>
>> -
>> Maxim Shafirov
>> JetBrains, Inc
>> http://www.jetbrains.com
>> "Develop with pleasure!"
>>> I have an reference to an PsiClass. The reference is correctly
>>> highlighted when pressing Ctrl and moving the mouse over it.
>>> It resolves to an an LightClassReference
>>> (PsiElementFactory.createClassReferenceElement(psiClass)).
>>> But 'Goto declaration' simply does nothing.
>>> What I am doing wrong?