[PATCH] D32859: [Analyzer] Iterator Checker - Part 5: Move Assignment of Containers

Balogh, Ádám via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Apr 26 06:50:06 PDT 2018


baloghadamsoftware updated this revision to Diff 144106.
baloghadamsoftware added a comment.
Herald added a reviewer: george.karpenkov.

One test failed after rebased to the current master branch. Depending on the internal implementation of the iterator and the move operation of the container it could happen that after moving a container the begin() or end() of the target of the move returns an already existing iterator position to the source of the move which is wrong. Therefore we must first check for begin() and end() and only then check for the existence of the iterator position of the return value of a function returning an iterator.


https://reviews.llvm.org/D32859

Files:
  lib/StaticAnalyzer/Checkers/IteratorChecker.cpp
  test/Analysis/mismatched-iterator.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D32859.144106.patch
Type: text/x-patch
Size: 12184 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180426/3f257ecf/attachment.bin>


More information about the cfe-commits mailing list