spool: Convert between ByteString and Vector.Storable without copying
This library allows conversion between the types from Data.ByteString
(package bytestring
) and Data.Vector.Storable
(package vector
) without
copying the underlying data. This is useful, for example, when ByteString
IO produces or consumes vectors of numbers in native byte order.
This trick relies on the fact that ByteString
and Vector
use their
respective ForeignPtr
s in compatible ways. It works with
bytestring-0.9.1.10
and vector-0.9
on GHC 7.0. It may break with future
releases of these packages. Depending on this library should be seen as a
way to document and standardize an existing hack, and not as an absolute
guarantee of correct behavior.
[Skip to Readme]
Downloads
- spool-0.1.tar.gz [browse] (Cabal source package)
- Package description (as included in the package)
Maintainer's Corner
For package maintainers and hackage trustees
Candidates
- No Candidates
Versions [RSS] | 0.1 |
---|---|
Dependencies | base (>=3 && <5), bytestring (>=0.9), vector (>=0.7) [details] |
License | BSD-3-Clause |
Author | Keegan McAllister <mcallister.keegan@gmail.com> |
Maintainer | Keegan McAllister <mcallister.keegan@gmail.com> |
Category | Data Structures |
Source repo | head: git clone git://github.com/kmcallister/spool.git |
Uploaded | by KeeganMcAllister at 2011-09-15T03:44:31Z |
Distributions | Debian:0.1, NixOS:0.1 |
Reverse Dependencies | 7 direct, 3 indirect [details] |
Downloads | 5117 total (50 in the last 30 days) |
Rating | (no votes yet) [estimated by Bayesian average] |
Your Rating | |
Status | Docs uploaded by user Build status unknown [no reports yet] |