Skip to content

Commit d86f87d

Browse files
Avoid overriding LSP_Uri '=' operator as abstract
This is no longer supported by the edge compiler, and we have multiple implicit equality comparisons in our code. Just add a comment warning the user that comparisons between Virtual_File objects should be prefered instead. For eng/shared/release#1774
1 parent 9dba4f8 commit d86f87d

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

liblsp_3_16/source/lsp-types.ads

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -294,15 +294,15 @@ package LSP.Types is
294294
subtype ProgressToken is LSP_Number_Or_String;
295295

296296
type LSP_URI is private;
297+
-- Type for LSP URI.
298+
-- Please avoind comparing URIs with "=": two URIs can point the same file
299+
-- even when they are distinct. In most case we shouldn't compare URIs,
300+
-- but find corresponding files using GNATCOLL.VFS and compare their
301+
-- normalized names instead.
297302

298303
function Equal (Left, Right : LSP_URI) return Boolean;
299304
-- Let's try to avoid URI comparison.
300305

301-
overriding function "=" (Left, Right : LSP_URI) return Boolean is abstract;
302-
-- Disable URI comparison with "=". Two URIs can point the same file
303-
-- even when they are distinct. In most case we shouldn't compare URIs,
304-
-- but find corresponding files and compare their normalized names.
305-
306306
function File_To_URI (File : String) return LSP.Types.LSP_URI;
307307
-- Turn the File name into an URI
308308

0 commit comments

Comments
 (0)