thomasjo / atom-ide-cpp

C/C++ language support for Atom-IDE
33 stars 4 forks source link

Weird ordering in the autocompletion dropdown #5

Open j4cobgarby opened 6 years ago

j4cobgarby commented 6 years ago

Here's a screenshot of what I mean:

screenshot from 2017-11-26 15-04-30

I don't know if this a problem just with me, but even though the plugin seems to know which option in the dropdown is most likely for me to want (since it's coloured bright white,) it's not at the top of the list.

This isn't so much of a problem in this case, but often the variable I'm looking for is too far down the list to see.

That's mainly a problem when using a library which declares some constants, whose names are hard to remember.

thomasjo commented 6 years ago

Yeah, this is currently a major limitation in Clangd, which returns completion items in a somewhat random order. I had hoped the recent addition of automatic sorting in atom-languageclient would resolve this problem, but turns out it doesn't. We'll most likely have to introduce some further additions to atom-languageclient to fully resolve this.

j4cobgarby commented 6 years ago

Is this issue being worked on?

thomasjo commented 6 years ago

@j4cobgarby Yes, but it requires fairly significant effort unless resolved upstream. Unfortunately I've been too busy to continue the work I started on in December. One upstream issue has been resolved that should make it easier on this end.

davydden commented 6 years ago

this is currently a major limitation in Clangd

should not this be reported upstream?

Cannedfood commented 5 years ago

I think this has been fixed upstream. The order I get makes sense. (clangd version 7.0.0) [edit]: Apart from autocompletion taking priority over makros