in reply to
Next & Last - Perl's Expect
You are trying to next in a loop outside of the scope in which the next is executed. The 'next' occurs in a subroutine which has no contextual relevance to the containing loop.
Comment on
Re: Next & Last - Perl's Expect
In Section
Seekers of Perl Wisdom