Parameters for constructor on auto-completion
JDT has a nice feature, when I Create an object
and my cursor is inside the brackets (), I hit Strg+Space and get a list of
possible constructors. This feature would be awesome for Scala IDE, too.
new ObjectWithParameters()
and my cursor is inside the brackets (), I hit Strg+Space and get a list of
possible constructors. This feature would be awesome for Scala IDE, too.
Leave a comment
on 2012-10-11 10:21 *
By Iulian Dragos
Component changed from None to Code Completion
Milestone set to Enhancements
Agreed, it would be nice. A first contribution, maybe? :)
on 2012-10-11 19:48 *
By nepomuk.seiler
Sounds charming. I see what I can do. This applies to methods as well AFAIK.
So this should be to hard. Is there a good starting point for this?
So this should be to hard. Is there a good starting point for this?
Seems a duplicate of #1001218
Daniel (Chia) correctly pointed out this is not a duplicate of #1001218 (though, the two tickets are somewhat related)
#1001218 is sort of a prerequisite for this ticket, since there needs to be a hook into completion of method Apply (since that's part of the AST generated for constructor call).
In scala-ide:5159853c495946c22f573934b457925078fd6f86 Added autocomplete for constructors.
This was done by adding an additional case to the completion logic
in ScalaCompletions.
To avoid problems with completion overwrites, similar to Eclipse Java
only tooltips are shown for constructor completion.
A known defect is the ability to complete constructors of classes with
mixins on the same line. See #1001950
Fix #1001272