Replaces a while loop with an equivalent do-while loop construct.