Index accessing checks are not performed for aliases
of std::array, as only std::array itself seems to be checked.
This patchs aims to extend it for aliases such as:
using MyArray = std::array<int, 10>;
Paths
| Differential D154297
clang-tidy: accessing checks not done for aliases of `std::array` ClosedPublic Authored by sousajo on Jul 2 2023, 1:30 AM.
Details Summary Index accessing checks are not performed for aliases This patchs aims to extend it for aliases such as:
Diff Detail
Event TimelineHerald added subscribers: PiotrZSL, carlosgalvezp, jeroen.dobbelaere and 3 others. · View Herald Transcript Comment Actions Looks good, probably hasCanonicalType would be sufficient but hasUnqualifiedDesugaredType will also do a job. This revision is now accepted and ready to land.Jul 2 2023, 11:31 AM Comment Actions Thanks ^^ added the release note. Can someone please land it for me? Jorge Pinto Sousa <jorge.pinto.sousa@proton.me> Comment Actions while landing it, if someone feels that the release note can/should be reworded please feel free to do so. Closed by commit rGce2d44b0ab6d: [clang-tidy] Accessing checks not done for aliases of `std::array` (authored by sousajo, committed by PiotrZSL). · Explain WhyJul 3 2023, 9:44 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 536805 clang-tools-extra/clang-tidy/cppcoreguidelines/ProBoundsConstantArrayIndexCheck.cpp
clang-tools-extra/docs/ReleaseNotes.rst
clang-tools-extra/test/clang-tidy/checkers/cppcoreguidelines/pro-bounds-constant-array-index.cpp
|