Skip to content

Commit 4b5ec95

Browse files
Anthony Leonardo GracioAnthonyLeonardoGracio
authored andcommitted
V609-058: Always disable snippets when not supported by client
1 parent 49f0ef9 commit 4b5ec95

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

source/ada/lsp-ada_handlers.adb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4139,10 +4139,10 @@ package body LSP.Ada_Handlers is
41394139

41404140
-- Check the 'useCompletionSnippets' flag to see if we should use
41414141
-- snippets in completion (if the client supports it).
4142-
if Ada.Has_Field (useCompletionSnippets) then
4143-
Self.Use_Completion_Snippets :=
4144-
Self.Completion_Snippets_Enabled
4145-
and then Ada.Get (useCompletionSnippets);
4142+
if not Self.Completion_Snippets_Enabled then
4143+
Self.Use_Completion_Snippets := False;
4144+
elsif Ada.Has_Field (useCompletionSnippets) then
4145+
Self.Use_Completion_Snippets := Ada.Get (useCompletionSnippets);
41464146
end if;
41474147

41484148
-- Retrieve the policy for displaying type hierarchy on navigation

0 commit comments

Comments
 (0)