[all-commits] [llvm/llvm-project] 031d3e: [clang-format] Fix a crash (assertion) in qualifie...

MyDeveloperDay via All-commits all-commits at lists.llvm.org
Thu Jan 6 11:45:55 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 031d3ece3f2eb6bd785dcf7484e88cc6a306db94
      https://github.com/llvm/llvm-project/commit/031d3ece3f2eb6bd785dcf7484e88cc6a306db94
  Author: mydeveloperday <mydeveloperday at gmail.com>
  Date:   2022-01-06 (Thu, 06 Jan 2022)

  Changed paths:
    M clang/lib/Format/QualifierAlignmentFixer.cpp
    M clang/lib/Format/QualifierAlignmentFixer.h
    M clang/unittests/Format/QualifierFixerTest.cpp

  Log Message:
  -----------
  [clang-format] Fix a crash (assertion) in qualifier alignment when matching template closer is null

https://github.com/llvm/llvm-project/issues/53008

```
template <class Id> using A = quantity /**/<kind<Id>, 1>;
```

the presence of the comment between identifier and template opener seems to be causing the qualifier alignment to fail

Reviewed By: curdeius

Fixes: #53008

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




More information about the All-commits mailing list