[all-commits] [llvm/llvm-project] c261f7: [clang-format] Refactor determineStarAmpUsage NFC

eywdck2l via All-commits all-commits at lists.llvm.org
Sun Apr 24 15:32:34 PDT 2022

  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: c261f78d05deee305166e5f8c91e347b8401dfa4
  Author: sstwcw <f0gukp2nk at protonmail.com>
  Date:   2022-04-24 (Sun, 24 Apr 2022)

  Changed paths:
    M clang/lib/Format/TokenAnnotator.cpp
    M clang/unittests/Format/FormatTest.cpp
    M clang/unittests/Format/TokenAnnotatorTest.cpp

  Log Message:
  [clang-format] Refactor determineStarAmpUsage NFC

There was some duplicate code in determineStarAmpUsage and

Now a `-` or `+` following `;`, `sizeof`, `co_await`, or `delete` is
regarded as a unary operator.

Now a `*` or `&` following `case` is also a unary operator.

Reviewed By: curdeius, MyDeveloperDay, HazardyKnusperkeks

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

More information about the All-commits mailing list