-
Notifications
You must be signed in to change notification settings - Fork 193
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrong insertion of guessed argument when "Completion overwrites" is chosen #500
Comments
|
Ready to test |
With 3.1.0.xx-201808210011-e47 it works as expected. |
The list of proposals for each parameter is built up in: https://github.com/groovy/groovy-eclipse/blob/master/ide/org.codehaus.groovy.eclipse.codeassist.completion/src/org/codehaus/groovy/eclipse/codeassist/completions/ParameterGuesserDelegate.java#L52 The array of enum elements is iterated from end to beginning. Not sure why it is done that way. Iterating in the natural order would probably give the result you expect. |
Not yet, I would expect |
Found while verifying #367.
Consider the following Java enum:
the following Java class:
and the following Groovy class:
Consider these options in Java | Editor | Content assist:
Invoke code assist at "|": you'll get
Utility.doSomething(VAL3)
(VAL3
highlighted) and then chooseVAL1
. The result is:Utility.doSomething(MyEnum.VAL3VAL1)
.If "Use static imports" is CHECKED, the result, instead, is:
Utility.doSomething(VAL3VAL1)
(the added static import is correct, though).The problem doesn't happen if you check "Completion inserts" instead of "Completion overwrites".
The text was updated successfully, but these errors were encountered: