just before iteration