Status: New Owner: ---- CC: anquetil...@gmail.com Labels: Type-Defect Priority-Medium Component-VerveineJ
New issue 638 by tu...@tudorgirba.com: VerveineJ seems to import some methods multiple times http://code.google.com/p/moose-technology/issues/detail?id=638
See the attached example.
DefaultConstructor::method() appears twice: once as a stub and once normal. The interesting thing is that the stub is the one that receives the invocation from the static method. This might be due to the following scenario: - the first visited method is methodWithClassScope(), - the invocation is created to a stub method() - the second visited method is method() - but somehow it is not reconciled with the already created stub method
package x;
public class DefaultConstructor {
public method() {} public static void methodWithClassScope() { DefaultConstructor x = new DefaultConstructor(); x.method(); } }
Attachments: DefaultConstructor.java 184 bytes
Updates: Status: WontFix
Comment #1 on issue 638 by anquetil...@gmail.com: VerveineJ seems to import some methods multiple times http://code.google.com/p/moose-technology/issues/detail?id=638
There is very little that can be done.
The problem comes from the fact that JDT's binding resolution is not successful for these methods. Therefore VerveineJ cannot link the invocation to the declaration. the only solution would be to do symbol resolution by hand, and this is exactly what I tried to avoid by using JDT's parser. (Incidently, if JDT cannot do it, verveineJ would probably not be able to do it either anyway.)
One question though is why JDT cannot resolve bindings in these cases?
For the example you give, the problem is that "method()" has no return type, so it is not valid.
For other cases, I would have to look at it to know. May be an incomplete classpath?
nicolas
Comment #2 on issue 638 by tu...@tudorgirba.com: VerveineJ seems to import some methods multiple times http://code.google.com/p/moose-technology/issues/detail?id=638
Thanks for looking into it. Indeed, the example was badly formed and so the error was not there. Actually, I think that the resolution was not bad at all in the current case.
Updates: Status: Invalid
Comment #3 on issue 638 by tu...@tudorgirba.com: VerveineJ seems to import some methods multiple times http://code.google.com/p/moose-technology/issues/detail?id=638
(No comment was entered for this change.)