A SparseArray maps integers to generic types. It allows gaps in incices, just like a Hash, but in a memory efficient manner. It is slower than a Hash though.
TODO:
- Support deletion
- Support Enumerable/Iterable
- dup/clone
- to_s/inspect
Add this to your application's shard.yml
:
dependencies:
sparse_array:
github: rumenzu/sparse_array
require "sparse_array"
- Fork it ( https://github.com/rumenzu/sparse_array/fork )
- Create your feature branch (git checkout -b my-new-feature)
- Commit your changes (git commit -am 'Add some feature')
- Push to the branch (git push origin my-new-feature)
- Create a new Pull Request
- rumenzu Romain Franceschini - creator, maintainer