File tree Expand file tree Collapse file tree
cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -515,7 +515,11 @@ private module Cached {
515515
516516 private predicate isSink ( Instruction instr , CallInstruction call ) {
517517 getAUse ( instr ) .( ArgumentOperand ) .getCall ( ) = call and
518- // Don't include various operations that don't modify what the iterator points to.
518+ // Only include operations that may modify the object that the iterator points to.
519+ // The following is a non-exhaustive list of things that may modify the value of the
520+ // iterator, but never the value of what the iterator points to.
521+ // The more things we can exclude here, the faster the small dataflow-like analysis
522+ // done by `convertsIntoArgument` will converge.
519523 not exists ( Function f | f = call .getStaticCallTarget ( ) |
520524 f instanceof Iterator:: IteratorCrementOperator or
521525 f instanceof Iterator:: IteratorBinaryArithmeticOperator or
You can’t perform that action at this time.
0 commit comments