Closed michaelpj closed 1 year ago
Extremely WIP branch here: https://github.com/michaelpj/lsp/tree/mpj/metamodel
I had to do the types for the metamodel manually since it seems like there isn't a maintained JSON schema library in Haskell, sadly.
Codegen is going to be annoying. In particular we're going to have to deal with all the anonymous intersections and unions that the spec throws around. Often we rationalized those into e.g. sensible sum types, but I'm not sure if we can do that here...
I'm making significant progress on this. I'm currently trying to deal with all the Method
s, which is a bit annoying since they've added a bunch more, and we have a lot of huge pattern matches for dealing with them. I may end up punting on this for the first version.
PR merged
https://github.com/microsoft/language-server-protocol/issues/67
There's a machine-readable specification of the protocol coming. It's specified in a non-standard way, so we'd have to do some work to process it, but it's probably still better than doing it by hand!