Hello Bill,
I just found your module List::Categorize and it seems convenient. I
noted however the line
my $category = &$coderef;
in the source. It is perhaps not technically a bug, but it could be
quite confusing if one tries to use @_ in the block. A contrived example:
categorize { pop; $_ } 1 .. 4 # (1 => [ 1 ], 2 => [ 2 ])
(See "What's the difference between calling a function as &foo and
foo()?" in perlfaq7 for more.)
This is easily fixed by just changing "&$coderef" to "&$coderef()" or
"$coderef->()", or a comment in the documentation if this indeed is the
intended behaviour.
Regards,
Johan Lodin