=> whatever partial identifier you have just typed, even if that does not yet exist anywhere else in the source, show that on top (so that when you press space, you always get what you have typed, and never some other completion.
No, I meant existing identifiers of course
It does not make sense to suggest non-existent items
Then I am at loss what you mean.
As I understand it, it already works that way.
I have my completion list sorted "Alphabetic (Scoped)". So when I complete in the below
program Project1;
var FooBar: integer;
procedure p1;
var
FooBarLocal: integer;
begin
Fooba // Completing here
end;
begin
end.
The list shows (locals before globals)
But as soon as I type the missing "r" my
"currently typed identifier" will be "FooBar"
2. currently typed identifier should always be first in the list, i.e. if I type `to` then it should be the first in the list, not `TObject`
"FooBar" exists, and the entry for the existing "FooBar" is the first in the list.
Of course that only works, if the word is in the list.
You are testing with the keyword "to", which in your case is (due to a different bug) not in the list. If it isn't in the list, it can't be on top of the list.
But the question is, if "for any word that is in the list" the "current" is not shown on top?