Next | Program Repair Shop | 241 |
Our main loop:
while (<INFILE>) { chomp; last if /^SCAN_CELLS/; $seen_CHAIN_TEST=1 if /CHAIN_TEST/;
if (/apply/ && $seen_CHAIN_TEST) { ... } }
Becomes:
while (<INFILE>) { chomp; last if /^SCAN_CELLS/; $seen_CHAIN_TEST=1 if /CHAIN_TEST/; next unless /apply/ && $seen_CHAIN_TEST;
... }
Next | Copyright © 2002 M. J. Dominus |