core: fix indexed loop checks
core: insert 'continue' instruction