[comp.lang.perl] Perl Pretty printer?

lwv27@CAS.BITNET (Larry W. Virden ext. 2487) (06/29/91)

Anyone have a perl pretty printer?  Someone recently posted the following,
and before I try to figure out where the missing newline is, I wanted
to reformat it...


#! /cas/tools/pdbin/sun4/perl
while(<>){chop;if($_ eq"%"){$t="";}elsif($t eq""){$t=$_;}else{$e{$t}.="$_\n";}
}srand;$_="CODE";while($_){s/^\W*//;print$&;if(s/^\w+//){if($e{$&}){split(/\n/,
$e{$&}); $_=$_[rand(1+$#_)].$_;}else{print$&;}}}
print
--
Larry W. Virden                 UUCP: osu-cis!chemabs!lwv27
Same Mbox: BITNET: lwv27@cas    INET: lwv27%cas.BITNET@CUNYVM.CUNY.Edu
Personal: 674 Falls Place,   Reynoldsburg,OH 43068-1614
America Online: lvirden