doc and test updates for `for` loop change