[all-commits] [llvm/llvm-project] 6f3f1e: [clangd] Remove trivial uses of FileEntry::getName

Sam McCall via All-commits all-commits at lists.llvm.org
Mon Apr 4 12:00:05 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 6f3f1e98686575004bef4257cbc6c825de5382af
      https://github.com/llvm/llvm-project/commit/6f3f1e98686575004bef4257cbc6c825de5382af
  Author: Sam McCall <sam.mccall at gmail.com>
  Date:   2022-04-04 (Mon, 04 Apr 2022)

  Changed paths:
    M clang-tools-extra/clangd/Diagnostics.cpp
    M clang-tools-extra/clangd/IncludeCleaner.cpp
    M clang-tools-extra/clangd/Preamble.cpp
    M clang-tools-extra/clangd/index/CanonicalIncludes.cpp
    M clang-tools-extra/clangd/index/FileIndex.cpp
    M clang-tools-extra/clangd/index/SymbolCollector.cpp
    M clang-tools-extra/clangd/refactor/Tweak.cpp
    M clang-tools-extra/clangd/refactor/tweaks/AddUsing.cpp
    M clang-tools-extra/clangd/unittests/IndexActionTests.cpp

  Log Message:
  -----------
  [clangd] Remove trivial uses of FileEntry::getName

It's deprecated; migrate to FileEntryRef::getName where it doesn't matter.
Also change one subtle case of implicit FileEntry::getName to be explicit.

After this patch, all the remaining FileEntry::getName calls are subtle
cases where we may be relying on exactly which filename variant is returned
(for indexing, IWYU directive handling, etc).




More information about the All-commits mailing list