Commit Graph

2 Commits

Author SHA1 Message Date
Adam Balogh b03ed5e414 [Analyzer] Iterator Checker - Part 2: Increment, decrement operators and ahead-of-begin checks
Add handling of the begin() funcion of containers to the iterator checkers,
together with the pre- and postfix ++ and -- operators of the iterators. This
makes possible the checking of iterators dereferenced ahead of the begin of the
container.

Differential Revision: https://reviews.llvm.org/D32642

llvm-svn: 335835
2018-06-28 10:58:53 +00:00
Artem Dergachev 8fa639ecf0 [analyzer] Initial commit for the upcoming refactoring of the IteratorChecker.
The new checker currently contains the very core infrastructure for tracking
the state of iterator-type objects in the analyzer: relating iterators to
their containers, tracking symbolic begin and end iterator values for
containers, and solving simple equality-type constraints over iterators.
A single specific check over this infrastructure is capable of finding usage of
out-of-range iterators in some simple cases.

Patch by Ádám Balogh!

Differential revision: https://reviews.llvm.org/D32592

llvm-svn: 304160
2017-05-29 15:03:20 +00:00