in reply to Re: Getting rid of "new" (wrong target; perl6)
in thread Getting rid of "new"
$Heap is scoped to the implicit BEGIN block.use Data::Heap::Whatever 1.1 ( \my $Heap, KeepTies => 1, CompactDump = +> 1 ); # ^^^^^^^^^ Factory object gets put into +this lexical variable my $bestScores= $Heap->new( '>', -max => 10 ); my $worstScores= $Heap->new( '<', -max => 10 );
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Getting rid of "new" (wrong target; perl6)
by tye (Sage) on Jul 11, 2006 at 12:59 UTC |