[all-commits] [llvm/llvm-project] 17747d: [clangd] Remove Tweak::Intent, use CodeAction kind...

Sam McCall via All-commits all-commits at lists.llvm.org
Fri Oct 2 02:15:00 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 17747d2ec8ec4471748197db54c8703f0c07c91c
      https://github.com/llvm/llvm-project/commit/17747d2ec8ec4471748197db54c8703f0c07c91c
  Author: Sam McCall <sam.mccall at gmail.com>
  Date:   2020-10-02 (Fri, 02 Oct 2020)

  Changed paths:
    M clang-tools-extra/clangd/ClangdLSPServer.cpp
    M clang-tools-extra/clangd/ClangdServer.cpp
    M clang-tools-extra/clangd/ClangdServer.h
    M clang-tools-extra/clangd/refactor/Tweak.h
    M clang-tools-extra/clangd/refactor/tweaks/AddUsing.cpp
    M clang-tools-extra/clangd/refactor/tweaks/AnnotateHighlightings.cpp
    M clang-tools-extra/clangd/refactor/tweaks/DefineInline.cpp
    M clang-tools-extra/clangd/refactor/tweaks/DefineOutline.cpp
    M clang-tools-extra/clangd/refactor/tweaks/DumpAST.cpp
    M clang-tools-extra/clangd/refactor/tweaks/ExpandAutoType.cpp
    M clang-tools-extra/clangd/refactor/tweaks/ExpandMacro.cpp
    M clang-tools-extra/clangd/refactor/tweaks/ExtractFunction.cpp
    M clang-tools-extra/clangd/refactor/tweaks/ExtractVariable.cpp
    M clang-tools-extra/clangd/refactor/tweaks/ObjCLocalizeStringLiteral.cpp
    M clang-tools-extra/clangd/refactor/tweaks/PopulateSwitch.cpp
    M clang-tools-extra/clangd/refactor/tweaks/RawStringLiteral.cpp
    M clang-tools-extra/clangd/refactor/tweaks/RemoveUsingNamespace.cpp
    M clang-tools-extra/clangd/refactor/tweaks/SwapIfBranches.cpp

  Log Message:
  -----------
  [clangd] Remove Tweak::Intent, use CodeAction kind directly. NFC

Intent was a nice idea but it ends up being a bit awkward/heavyweight
without adding much.

In particular, it makes it hard to implement `CodeActionParams.only` properly
(there's an inheritance hierarchy for kinds).

Differential Revision: https://reviews.llvm.org/D88427




More information about the All-commits mailing list