What version of perl and List::Util? With perl 5.6.1 and List::Util 1.09, that first version gives me a segfault. I know that List::Util has had stack issues in the past when you do anything non-trivial in the code block, I don't know if that has anything to do with it.
Update: Just updated to List::Util 1.11 - Same result.