Skip to content
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

Unhelpful code completion options in constructor params #250

Closed
sethladd opened this issue Jan 26, 2017 · 3 comments
Closed

Unhelpful code completion options in constructor params #250

sethladd opened this issue Jan 26, 2017 · 3 comments

Comments

@sethladd
Copy link

sethladd commented Jan 26, 2017

Tried to see what other named parameters I could provide. Here's what I saw:

screen shot 2017-01-25 at 12 03 26 pm

Can we do something better here? Can we show only named parameters?

Thanks!

(not sure if this plugin can do something to help, or if we are constrained by what analyzer can tell us... thought I'd open this issue first)

@sethladd sethladd changed the title Unhelpful code completion options Unhelpful code completion options in constructor params Jan 26, 2017
@DanTup
Copy link
Member

DanTup commented Jan 26, 2017

These things all come from the analyzer. We do get back a relevance field but the Code API doesn't have anywhere to put it and I don't think a non-alphabetical sort would be nice here even if accepted and sorted by it.

I think it's by design that the analyzer returns too much and lets the client filter and usually that seems to work fine. In this case, if it's invalid to put anything other than a parameter name here (I presume you can only put more named params after you already put one?) then maybe the analyzer could filter this list, or at least something to let us filter them out if it makes sense for our IDE.

I wonder if @bwilkerson has any thoughts on this?

I think dart-lang/sdk#27034 is slightly related to this; with that implemented I think Code would give you information about the signature of the constructor you're calling (though I think it'd be ideal if the list was filtered too).

@bwilkerson
Copy link

This is definitely an issue that should be solved in the server; all of our clients have the same issue and need the same solution.

@sethladd Can you move this issue into the sdk issue tracker? (I don't know the magic incantation.)

@DanTup DanTup added is enhancement blocked on dart / flutter Requires a change in Dart or Flutter to progress labels Jan 26, 2017
@DanTup DanTup added fixed in dart / flutter and removed blocked on dart / flutter Requires a change in Dart or Flutter to progress labels Feb 25, 2017
@DanTup
Copy link
Member

DanTup commented Feb 25, 2017

Based on dart-lang/sdk#28529 (comment) I expect this will be fixed in Dart 1.23 :-)

@DanTup DanTup closed this as completed Feb 25, 2017
@DanTup DanTup modified the milestones: v1.0, v1.1 Feb 25, 2017
@DanTup DanTup modified the milestones: v1.1, v1.0.2 Mar 24, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants