haskell / lsp

Haskell library for the Microsoft Language Server Protocol
360 stars 89 forks source link

Don't add deprecation pragmas to deprecated fields in the metamodel #495

Closed michaelpj closed 1 year ago

michaelpj commented 1 year ago

Deprecated fields in the metamodel are usually optional, and so the correct behaviour is to omit them. We can't really do that since we represent optional fields with a Maybe. "Omitting" the field means putting Nothing there, which is still using it as far as Haskell is concerned, so a Haskell deprecation warning will fire there.

The correct thing to do would be something like "deprecated if set to anything except Nothing", but we can't do that so we should just not do anything.

michaelpj commented 1 year ago

Done