[PATCH] D66564: [clang-tidy] new altera struct pack align check
Aaron Ballman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sat May 23 07:24:07 PDT 2020
aaron.ballman accepted this revision.
aaron.ballman added a comment.
This revision is now accepted and ready to land.
Aside from a minor nit with the matcher, this LGTM!
================
Comment at: clang-tools-extra/clang-tidy/altera/StructPackAlignCheck.cpp:50-53
+ // Do not trigger on template instantiations because the packing and
+ // alignment requirements are unknown.
+ if (Struct->isTemplated())
+ return;
----------------
I think this should be hoisted into the AST matcher using `unless(isTemplateInstantiation())`.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D66564/new/
https://reviews.llvm.org/D66564
More information about the cfe-commits
mailing list