[all-commits] [llvm/llvm-project] 6c7870: [AST] Fix the incorrect auto-keyword loc for const...

Haojian Wu via All-commits all-commits at lists.llvm.org
Wed Jan 19 05:19:10 PST 2022


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

  Changed paths:
    M clang-tools-extra/clang-tidy/modernize/UseTrailingReturnTypeCheck.cpp
    M clang/lib/Parse/ParseDecl.cpp
    M clang/unittests/AST/SourceLocationTest.cpp

  Log Message:
  -----------
  [AST] Fix the incorrect auto-keyword loc for constrained auto type loc.

E.g.  `Concept auto Func();`

The nameLoc for the constained auto type loc pointed to the concept name
loc, it should be the auto token loc. This patch fixes it, and remove
a relevant hack in clang-tidy check.

Reviewed By: sammccall

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




More information about the All-commits mailing list