What would be a more robust way of solving this?
I think natural sort - as Corion suggested - would fit the bill quite well:
use Data::Dumper; use Sort::Naturally; $Data::Dumper::Sortkeys = sub { my ($hash) = @_; return [ nsort( keys %$hash ) ]; };
In reply to Re^2: Using Data::Dumpers Sortkeys subroutine
by almut
in thread Using Data::Dumpers Sortkeys subroutine
by nysus
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |