]> granicus.if.org Git - clang/commit
[Analyzer] Instead of recording comparisons in interator checkers do an eager state...
authorAdam Balogh <adam.balogh@ericsson.com>
Tue, 23 Apr 2019 07:15:55 +0000 (07:15 +0000)
committerAdam Balogh <adam.balogh@ericsson.com>
Tue, 23 Apr 2019 07:15:55 +0000 (07:15 +0000)
commita73b9783aa3f1b642ccffa92e4348389b3f3d54e
treedbff191eca5834a426c3d57257e3c6658a86a9e5
parentde154851ca2a78dc229688318ae7f6840597eafd
[Analyzer] Instead of recording comparisons in interator checkers do an eager state split

Currently iterator checkers record comparison of iterator positions
and process them for keeping track the distance between them (e.g.
whether a position is the same as the end position). However this
makes some processing unnecessarily complex and it is not needed at
all: we only need to keep track between the abstract symbols stored
in these iterator positions. This patch changes this and opens the
path to comparisons to the begin() and end() symbols between the
container (e.g. size, emptiness) which are stored as symbols, not
iterator positions. The functionality of the checker is unchanged.

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

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@358951 91177308-0d34-0410-b5e6-96231b3b80d8
lib/StaticAnalyzer/Checkers/IteratorChecker.cpp