sub iterator { my $self = shift; open my $TT, "<:encoding(UTF-8)", $file or die; return sub { while ( defined (my $rec = <$TT>) ) { confess ( "Error, stopped" ) unless $something; } close $TT; return; }; }
[download]