sub process_file { my ($fh) = @_; while ( my $line = <$fh> ) { print $line; if ( $line =~ /section start marker/ ) { $line = handle_section($fh); redo if defined $line; } } } ... sub handle_section { ... return $line; }
In reply to Re^2: Use Perl's Sort to only sort certain lines in a file?
by Anonymous Monk
in thread Use Perl's Sort to only sort certain lines in a file?
by grahambuck
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |