Currently, some patterns will lead to failure, but there is no warning. The are the cases where we are current iterating over an array or an object and within the loop, we access the array or the object being iterated over.
for(auto value : myobject) {
myobject.reset();
}
or
for(auto value : myobject) {
if(...) { myobject["mykey"]; }
}