Auto complete preselects obscure method before basic language constants (like false)

This may have been asked many times. When entering code, my intent in the pic is to return false;, here are the autocomplete suggestions I get:

autocomplete suggestions I get

Can I force PhpStorm to preselect false before all other obscure (aka much more infrequent targets)? That would improve (much) my user experience. 

Sorry for dumb question, I could not find it here.

PhpStorm 2016.1.2, OSX 10.11.5

 

FYI : I asked the same on SO, and followed all the suggested holy rituals and voodoo incantations, before posting here.  No beans. 

http://stackoverflow.com/questions/37325043/auto-complete-preselects-obscure-method-before-basic-language-constants-like-fa 

8 comments
Comment actions Permalink

The list of suggestions is sorted dynamically based on the functions usage - we can't tune it the way we want. 

`False` should get on a first place once IDE counts amount & frequency of its usages sufficient.

0
Comment actions Permalink

@Dmitry : lets make this simple. I NEVER select fbird_* , fastcgi_*.

IMNSHO the sort should on semantic distance from the declaration before any other. Language intrinsics are distance 0.

And now, how about some real help Dmitry ? how (and where) can i suppress whatever garbage history PhpStorm uses to conclude that i use fastcgi_* more often than false ?  

errr ... I am curious, just asking if you ever coded in PHP. Do you use any library symbol more often than language intrinsics ?????

By the way I have totally crazy other examples to show you  from that project. Trust me, it is a bug.

 

 

 

 

0
Comment actions Permalink

One more comment : even if i buy into 'sort on frequency of usage' i would point out that based on your statement, the sort is ok. What really (really) gets me is that the **preselected** pick is the one i never use.

 

0
Comment actions Permalink

Unfortunately there's no way to filter this out (at least now), see https://youtrack.jetbrains.com/issue/WI-5731 for details (don't forget to vote for it).

As for an unused function being preselected in a suggestion list: you can submit this as a bug report at http://youtrack.jetbrains.com/issues/WI#newissue=yes or describe your problem in https://youtrack.jetbrains.com/issue/WI-31973 - this thread is partially discussing the same problem.

0
Comment actions Permalink

Added new bug in Youtrack : https://youtrack.jetbrains.com/issue/WI-32340

Still, you have not answered : how can i make PhpStorm 'forget' the sort order and start from fresh in a project ? 

0
Comment actions Permalink

It's IDE-wide, based on a file extension. So generally by wiping all IDE-specific settings. I'll check with a team if this can be done without deleting all the caches/configs.

0
Comment actions Permalink

Running File > Invalidate Caches / Restart ...should reset a completion list for current project.

0
Comment actions Permalink

For the benefit of onlookers : work in progress here, this will be fixed (yeahhh!!) 

https://youtrack.jetbrains.com/issue/WI-32340

0

Please sign in to leave a comment.