Skip to content

Commit

Permalink
completion: fix list-symbols pruning
Browse files Browse the repository at this point in the history
Fix how list-symbols prunes local variables defined after the cursor
  • Loading branch information
Prince781 committed Apr 15, 2020
1 parent e6dbdb1 commit 5355688
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/completion/completionengine.vala
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ namespace Vls.CompletionEngine {
var sr = sym.source_reference;
if (sr == null)
continue;
var sr_begin = new Position () { line = sr.begin.line, character = sr.begin.column - 1 };
var sr_begin = new Position.from_libvala (sr.begin);

// don't show local variables that are declared ahead of the cursor
if (sr_begin.compare_to (pos) > 0)
Expand Down

0 comments on commit 5355688

Please sign in to comment.