[PATCH] D150446: [analyzer] Check ArraySubscriptExprs in ArrayBoundCheckerV2
DonĂ¡t Nagy via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri May 12 06:56:14 PDT 2023
donat.nagy added a comment.
After some thinking and internal discussion I decided that it'd be better to replace the callback used by this checker. This is a clean but rough draft of this concept; for a final version I'd consider:
- adding a secondary callback that handles `*ptr` equivalently to `ptr[0]`;
- including a special case that it's valid to form an after-the-end pointer as `&arr[N]` where `N` is the length of the array;
- including a check::Location callback that creates bug reports when these after-the-end pointers are dereferenced.
@steakhal What do you think about this design direction?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D150446/new/
https://reviews.llvm.org/D150446
More information about the cfe-commits
mailing list