Commit Graph

9 Commits

Author SHA1 Message Date
micbou
5981809681
Support FixIts in TypeScript completions 2018-04-25 05:08:23 +02:00
micbou
3b115831a0
Fix applying fixit twice after completion 2018-04-06 17:56:25 +02:00
micbou
866693ef80
Refactor CompleteDone logic
Move CompleteDone logic to the CompletionRequest class.
2018-03-28 22:00:43 +02:00
Ben Jackson
7989b7b0fd Support for additional FixIts on java completions
Java completer can include FixIts which are applied when a completion
entry is selected. We use the existing mechanism implemented for c-sharp
to perform these edits using the CompleteDone autocommand.

However, the existing mechanism relies on pattern matching the source to
work out which item was completed. Vim patch 8.0.1493 introduces support
for user_data on completion items, so when available we populate it with
the completion array index of the item and use that to get the exact
element that was selected. This is both a lot faster and a lot more
accirate.

Of course when applying these 'FixIts' we don't interrupt the user with
confirmation or the quickfix list as this would just be annoying. If the
server reports that an edit must be made, we just make the edit. This is
achieved by adding a silent flag to ReplaceChunks.
2018-02-11 18:11:34 +00:00
micbou
1fc6b4a43b
Clean C# inserting namespace code
Remove code that automatically insert namespaces in C# for Vim versions prior
to 7.4.774.
2017-05-17 19:44:02 +02:00
micbou
f3ccafe3ae
Do not install aliases from future
Installing aliases from python-future is unreliable and slow.
2017-03-18 18:24:48 +01:00
micbou
fa10f33c2a
Move test_utils to tests folder
This remove the file from coverage.
2016-10-15 04:03:48 +02:00
micbou
8d015c95cc
Refactor tests using a YouCompleteMe instance 2016-10-14 02:18:51 +02:00
micbou
cbe53c1f3e
Rename postcomplete tests file
Rename postcomplete_tests.py file to be consistent with other tests
name. Update its copyright date.
2016-10-12 05:13:06 +02:00