[all-commits] [llvm/llvm-project] bb6d96: [clangd] Enable modules to contribute tweaks.
kadir çetinkaya via All-commits
all-commits at lists.llvm.org
Tue Apr 13 08:50:45 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: bb6d96ced80f288475cd374c3c7a25ee8cad2bb2
https://github.com/llvm/llvm-project/commit/bb6d96ced80f288475cd374c3c7a25ee8cad2bb2
Author: Kadir Cetinkaya <kadircet at google.com>
Date: 2021-04-13 (Tue, 13 Apr 2021)
Changed paths:
M clang-tools-extra/clangd/ClangdServer.cpp
M clang-tools-extra/clangd/FeatureModule.h
M clang-tools-extra/clangd/refactor/Tweak.cpp
M clang-tools-extra/clangd/refactor/Tweak.h
M clang-tools-extra/clangd/tool/Check.cpp
M clang-tools-extra/clangd/unittests/CMakeLists.txt
A clang-tools-extra/clangd/unittests/FeatureModulesTests.cpp
M clang-tools-extra/clangd/unittests/tweaks/TweakTesting.cpp
Log Message:
-----------
[clangd] Enable modules to contribute tweaks.
First patch to enable diagnostic fix generation through modules. The
workflow will look like:
- ASTWorker letting modules know about diagnostics while building AST,
modules can read clang::Diagnostic and mutate clangd::Diagnostic through
that hook.
- Modules can implement and expose tweaks to fix diagnostics or act as
general refactorings.
- Tweak::Selection will contain information about the diagnostic
associated with the codeAction request to enable modules to fail their
diagnostic fixing tweakson prepare if need be.
Differential Revision: https://reviews.llvm.org/D98498
Commit: bce3ac4f224aa7da0b253852ce8a28ad5a39c31f
https://github.com/llvm/llvm-project/commit/bce3ac4f224aa7da0b253852ce8a28ad5a39c31f
Author: Kadir Cetinkaya <kadircet at google.com>
Date: 2021-04-13 (Tue, 13 Apr 2021)
Changed paths:
M clang-tools-extra/clangd/ClangdServer.cpp
M clang-tools-extra/clangd/ClangdServer.h
M clang-tools-extra/clangd/Compiler.h
M clang-tools-extra/clangd/Diagnostics.cpp
M clang-tools-extra/clangd/Diagnostics.h
M clang-tools-extra/clangd/FeatureModule.h
M clang-tools-extra/clangd/ParsedAST.cpp
M clang-tools-extra/clangd/Preamble.cpp
M clang-tools-extra/clangd/unittests/ClangdLSPServerTests.cpp
M clang-tools-extra/clangd/unittests/DiagnosticsTests.cpp
M clang-tools-extra/clangd/unittests/TestTU.cpp
M clang-tools-extra/clangd/unittests/TestTU.h
Log Message:
-----------
[clangd] Introduce ASTHooks to FeatureModules
These can be invoked at different stages while building an AST to let
FeatureModules implement features on top of it. The patch also
introduces a sawDiagnostic hook, which can mutate the final clangd::Diag
while reading a clang::Diagnostic.
Differential Revision: https://reviews.llvm.org/D98499
Commit: b5b2c81055cfd0cc6a2a1d1ff2c8017d422586dc
https://github.com/llvm/llvm-project/commit/b5b2c81055cfd0cc6a2a1d1ff2c8017d422586dc
Author: Kadir Cetinkaya <kadircet at google.com>
Date: 2021-04-13 (Tue, 13 Apr 2021)
Changed paths:
M clang-tools-extra/clangd/Diagnostics.cpp
M clang-tools-extra/clangd/Diagnostics.h
M clang-tools-extra/clangd/Protocol.cpp
M clang-tools-extra/clangd/Protocol.h
M clang-tools-extra/clangd/refactor/Tweak.h
Log Message:
-----------
[clangd] Propagate data in diagnostics
Differential Revision: https://reviews.llvm.org/D98505
Compare: https://github.com/llvm/llvm-project/compare/0b63e3222b2d...b5b2c81055cf
More information about the All-commits
mailing list