emacs-lsp / emacs-ccls

Emacs client for ccls, a C/C++ language server
200 stars 29 forks source link

Use lsp-protocol.el #89

Closed ericdallo closed 4 years ago

ericdallo commented 4 years ago

lsp-mode is migrating to use lsp-protocol.el and support for plists instead of hash-tables. We already migrated almost all lsp repos and ccls is one of the missing ones: https://github.com/emacs-lsp/lsp-mode/issues/1751

@MaskRay willing to migrate ccls to use it?

MaskRay commented 4 years ago

I'm willing to migrate. I haven't touched elisp for quite some time and I need to get my feet wet with it...

ericdallo commented 4 years ago

Great :) Feel free to ask for help if you want.

MaskRay commented 4 years ago

Is there a list of changes that I should pay attention to? It is not very like what APIs should be migrated...

ericdallo commented 4 years ago

@MaskRay We are supporting plists now, so every place where it handles as hash-table should change to use the lsp-protocol.el, example: (gethash "start" range) -> (lsp:range-start range) ((&hash "start") range) -> ((&Range :start) range)

Maybe @yyoncho can give more details

yyoncho commented 4 years ago

@MaskRay

Access to all datastrutures coming from the server should happen via lsp-protocol. Here are examples of how to use it: https://github.com/yyoncho/lsp-mode/blob/master/lsp-protocol.el . A good test if everything works is setting lsp-use-plists to t and recompiling lsp related projects. If you see something that doesn't work, please report it in corresponding repo.

ericdallo commented 4 years ago

Thank you!