Interestingly enough, I can goto outside of an eval block without any complaints:
...re your update - that's a neat trick that I'll have to tuck away.#!/usr/bin/perl use strict; use warnings; my $begin='banana'; my $end='grape'; while(<DATA>) { /$begin/ ? eval { /$end/ ? goto END : print while (<DATA>) } : next } END: exit; __DATA__ apple banana pear peach grape orange
In reply to Re: Re4: Finding part of a file
by belden
in thread Finding part of a file
by willa
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |