Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/coldfix/perl-ohashi
Ordered case-insensitive hashes for perl. Without dependencies.
https://github.com/coldfix/perl-ohashi
Last synced: 25 days ago
JSON representation
Ordered case-insensitive hashes for perl. Without dependencies.
- Host: GitHub
- URL: https://github.com/coldfix/perl-ohashi
- Owner: coldfix
- License: other
- Created: 2013-06-29T18:32:56.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2013-08-15T04:20:00.000Z (about 11 years ago)
- Last Synced: 2023-03-24T13:30:20.789Z (over 1 year ago)
- Language: Perl
- Homepage:
- Size: 121 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: COPYING
Awesome Lists containing this project
README
### perl-ohashi
Very lightweight order-preserving case-insensitive hashes for perl.
#### Features
* no dependencies on any non-core modules
* very little code logic
* implemented as linked list to improve lookup speed on iteration#### Usage
`ohashi`s can be created as references:
```perl
my $x = new ohashi(alpha => 'foo', beta => 'bar');
print $x->{AlpHA}; # prints 'foo'
```or tied to a new variable:
```perl
tie (my %x, 'ohashi',
alpha => 1, beta => 2));
```**Don't** try this:
```perl
my %x = (pi => 3.14);
tie (%x, 'ohashi');
```