[all-commits] [llvm/llvm-project] cb9ccd: [clangd] Move the selection decltype hack to getSo...

Haojian Wu via All-commits all-commits at lists.llvm.org
Tue Jan 4 03:12:24 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: cb9ccd38c55f729a6bd7986bbdcb34755b774240
      https://github.com/llvm/llvm-project/commit/cb9ccd38c55f729a6bd7986bbdcb34755b774240
  Author: Haojian Wu <hokein.wu at gmail.com>
  Date:   2022-01-04 (Tue, 04 Jan 2022)

  Changed paths:
    M clang-tools-extra/clangd/Selection.cpp
    M clang-tools-extra/clangd/unittests/SelectionTests.cpp

  Log Message:
  -----------
  [clangd] Move the selection decltype hack to getSourceRange.

Previously, it was in canSafelySkipNode, which is only used to decide
whether we should descend into it and its children, and we still used
the incomplete Decltypeloc.getSourceRange() to claim tokens, which will
cause some tokens were not claimed correctly.

Separate a change of https://reviews.llvm.org/D116536

Reviewed By: sammccall

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




More information about the All-commits mailing list