[PATCH] D39430: [clangd] formatting: don't ignore style

Raoul Wols via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sun Nov 26 08:16:40 PST 2017


rwols updated this revision to Diff 124307.
rwols added a comment.

- Rebase to latest upstream revision.
- Go all-in with TextEdit, even down to ClangdUnit.cpp.
- Move FixItsMap to ClangdServer. ClangdLSPServer is much cleaner now.
- Remove the cached FixIts when the client closes the document.
- Fix (or introduce bug?) wrong conversion between clang line/columns and LSP line/columns. From what I understand, clang line/cols are 1-based, and LSP line/cols are 0-based. The line numbers were already converted correctly (subtracting 1 when going from clang line numbers to LSP line numbers), but the column numbers were not converted correctly. Consequently, a bunch of tests had to be adjusted for the correct (or wrong?) column numbers.


https://reviews.llvm.org/D39430

Files:
  clangd/ClangdLSPServer.cpp
  clangd/ClangdLSPServer.h
  clangd/ClangdServer.cpp
  clangd/ClangdServer.h
  clangd/ClangdUnit.cpp
  clangd/ClangdUnit.h
  clangd/JSONRPCDispatcher.cpp
  clangd/JSONRPCDispatcher.h
  test/clangd/diagnostics.test
  test/clangd/execute-command.test
  test/clangd/extra-flags.test
  test/clangd/fixits.test

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D39430.124307.patch
Type: text/x-patch
Size: 33749 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20171126/39c8f68e/attachment-0001.bin>


More information about the cfe-commits mailing list