This revision was automatically updated to reflect the committed changes.
Closed by commit rG9e1a4ce0b55d: [clang-tidy] Fix for
bugprone-sizeof-expression PR57167 (authored by chrish_ericsson_atx).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
chrish_ericsson_atx updated this revision to Diff 453442.
chrish_ericsson_atx added a comment.
Removed `// FIXME` comments, per @aaron.ballman's feedback.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D131926/new/
https://reviews.llvm.org/D131926
Files:
chrish_ericsson_atx added inline comments.
Comment at:
clang-tools-extra/test/clang-tidy/checkers/bugprone/sizeof-expression.cpp:236-238
- // CHECK-MESSAGES: :[[@LINE-1]]:10: warning: suspicious usage of
'sizeof(A*)'; pointer to aggregate
sum += sizeof(PMyStruct);
- //
aaron.ballman accepted this revision.
aaron.ballman added a comment.
LGTM aside from removing some comments now that we figured out what's going on.
Please hold off on landing for a day or two in case @njames93 has other
opinions though.
Comment at:
mizvekov added inline comments.
Comment at:
clang-tools-extra/test/clang-tidy/checkers/bugprone/sizeof-expression.cpp:236-238
- // CHECK-MESSAGES: :[[@LINE-1]]:10: warning: suspicious usage of
'sizeof(A*)'; pointer to aggregate
sum += sizeof(PMyStruct);
- //
aaron.ballman added inline comments.
Comment at:
clang-tools-extra/test/clang-tidy/checkers/bugprone/sizeof-expression-2.c:42
+ sum += sizeof(__typeof());
+ sum += sizeof(STRKWD MyStruct*);
+ sum += sizeof(__typeof(STRKWD MyStruct*));
Based on the
chrish_ericsson_atx updated this revision to Diff 453286.
chrish_ericsson_atx added a comment.
Corrected git-clang-format issue.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D131926/new/
https://reviews.llvm.org/D131926
Files:
chrish_ericsson_atx added a comment.
Sounds fair. I had taken your acceptance of the change as a green light. :)
TBH, the acceptance came much faster than I'd expected-- even though this is a
trivial and low-risk change, I expected it to sit for at least several days.
I'll plan to wait a
mizvekov added inline comments.
Comment at:
clang-tools-extra/test/clang-tidy/checkers/bugprone/sizeof-expression.cpp:236-238
- // CHECK-MESSAGES: :[[@LINE-1]]:10: warning: suspicious usage of
'sizeof(A*)'; pointer to aggregate
sum += sizeof(PMyStruct);
- //
chrish_ericsson_atx added inline comments.
Comment at:
clang-tools-extra/test/clang-tidy/checkers/bugprone/sizeof-expression.cpp:236-238
- // CHECK-MESSAGES: :[[@LINE-1]]:10: warning: suspicious usage of
'sizeof(A*)'; pointer to aggregate
sum += sizeof(PMyStruct);
- //
chrish_ericsson_atx updated this revision to Diff 453022.
chrish_ericsson_atx added a comment.
Added missing newline and added // FIXME comments, per reviewer comments.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D131926/new/
https://reviews.llvm.org/D131926
Files:
mizvekov added inline comments.
Comment at:
clang-tools-extra/test/clang-tidy/checkers/bugprone/sizeof-expression.cpp:236-238
- // CHECK-MESSAGES: :[[@LINE-1]]:10: warning: suspicious usage of
'sizeof(A*)'; pointer to aggregate
sum += sizeof(PMyStruct);
- //
chrish_ericsson_atx added inline comments.
Comment at:
clang-tools-extra/test/clang-tidy/checkers/bugprone/sizeof-expression.cpp:236-238
- // CHECK-MESSAGES: :[[@LINE-1]]:10: warning: suspicious usage of
'sizeof(A*)'; pointer to aggregate
sum += sizeof(PMyStruct);
- //
njames93 added a comment.
Please can you run git clang-format over the patch to keep the pre-merge bot
happy.
Comment at:
clang-tools-extra/test/clang-tidy/checkers/bugprone/sizeof-expression.cpp:236-238
- // CHECK-MESSAGES: :[[@LINE-1]]:10: warning: suspicious usage of
mizvekov accepted this revision.
mizvekov added a comment.
This revision is now accepted and ready to land.
LGTM once minor nits are fixed. I am not opposed to getting this back to where
it was, we can take a more careful look later at what this checker should be
doing instead.
chrish_ericsson_atx created this revision.
chrish_ericsson_atx added reviewers: mizvekov, baloghadamsoftware, njames93,
cfe-commits.
Herald added subscribers: carlosgalvezp, rnkovacs, xazax.hun.
Herald added a project: All.
chrish_ericsson_atx requested review of this revision.
Herald added a
16 matches
Mail list logo