[PATCH] D131319: [clang-tidy] Update llvm-prefer-isa-or-dyn-cast-in-conditionals with new syntax
Carlos Galvez via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sun Apr 23 03:15:54 PDT 2023
carlosgalvezp added inline comments.
================
Comment at: clang-tools-extra/clang-tidy/llvm/PreferIsaOrDynCastInConditionalsCheck.h:61
+private:
+ mutable std::optional<bool> HasIsPresent;
};
----------------
njames93 wrote:
> PiotrZSL wrote:
> > no need for mutable, its used only form Check that isn't const.
> > Maybe better HasIsPresentCache ?
> Good spot.
Comment not yet addressed, do you intend to?
================
Comment at: clang-tools-extra/docs/ReleaseNotes.rst:323
+ use the ``*and_present`` and ``*if_present`` templates added in
+ `D123901 <https://reviews.llvm.org/D123901>`_.
+
----------------
Would it make more sense to point to an actual commit in the repo? A review may or may not have been merged.
================
Comment at: clang-tools-extra/test/clang-tidy/checkers/llvm/prefer-isa-or-dyn-cast-in-conditionals.cpp:1
-// RUN: %check_clang_tidy %s llvm-prefer-isa-or-dyn-cast-in-conditionals %t
-
+// RDUN: %check_clang_tidy -check-suffixes=,NO-PRESENT %s llvm-prefer-isa-or-dyn-cast-in-conditionals %t
+// RUN: %check_clang_tidy -check-suffixes=,PRESENT %s llvm-prefer-isa-or-dyn-cast-in-conditionals %t -- -- -DISA_AND_PRESENT
----------------
Typo
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D131319/new/
https://reviews.llvm.org/D131319
More information about the cfe-commits
mailing list