Acme-CPANModules-OrderedHash

 view release on metacpan or  search on metacpan

README  view on Meta::CPAN


     % bencher --module-startup --cpanmodules-module OrderedHash

    For more options (dump scenario, list/include/exclude/add participants,
    list/include/exclude/add datasets, etc), see bencher or run "bencher
    --help".

DESCRIPTION
    When you ask a Perl's hash for the list of keys, the answer comes back
    unordered. In fact, Perl explicitly randomizes the order of keys it
    returns everytime. The random ordering is a (security) feature, not a
    bug. However, sometimes you want to know the order of insertion. These
    modules provide you with an ordered hash; most of them implement it by
    recording the order of insertion of keys in an additional array.

    Other related modules:

    Tie::SortHash - will automatically sort keys when you call keys(),
    values(), each(). But this module does not maintain insertion order.

ACME::CPANMODULES ENTRIES

lib/Acme/CPANModules/OrderedHash.pm  view on Meta::CPAN

our $DATE = '2025-04-15'; # DATE
our $DIST = 'Acme-CPANModules-OrderedHash'; # DIST
our $VERSION = '0.004'; # VERSION

our $LIST = {
    summary => "List of modules that provide ordered hash data type",
    description => <<'MARKDOWN',

When you ask a Perl's hash for the list of keys, the answer comes back
unordered. In fact, Perl explicitly randomizes the order of keys it returns
everytime. The random ordering is a (security) feature, not a bug. However,
sometimes you want to know the order of insertion. These modules provide you
with an ordered hash; most of them implement it by recording the order of
insertion of keys in an additional array.

Other related modules:

<pm:Tie::SortHash> - will automatically sort keys when you call `keys()`,
`values()`, `each()`. But this module does not maintain insertion order.

MARKDOWN

lib/Acme/CPANModules/OrderedHash.pm  view on Meta::CPAN

To run module startup overhead benchmark:

 % bencher --module-startup --cpanmodules-module OrderedHash

For more options (dump scenario, list/include/exclude/add participants, list/include/exclude/add datasets, etc), see L<bencher> or run C<bencher --help>.

=head1 DESCRIPTION

When you ask a Perl's hash for the list of keys, the answer comes back
unordered. In fact, Perl explicitly randomizes the order of keys it returns
everytime. The random ordering is a (security) feature, not a bug. However,
sometimes you want to know the order of insertion. These modules provide you
with an ordered hash; most of them implement it by recording the order of
insertion of keys in an additional array.

Other related modules:

L<Tie::SortHash> - will automatically sort keys when you call C<keys()>,
C<values()>, C<each()>. But this module does not maintain insertion order.

=head1 ACME::CPANMODULES ENTRIES



( run in 1.182 second using v1.01-cache-2.11-cpan-39bf76dae61 )