Fix crash on empty body branches in a loop in Next cop

This fixes #1191.
Merge pull request #1193 from yujinakayama/fix-crash-in-next

Fix crash in Next cop