pristine:9bb211e35cb5d627bcf5eb2549861d0209466d3addf9f4e99b8c1294df55de02 [Start of a bit parsing library Lennart Kolmodin **20100816213318 Ignore-this: c344da4549645a20bd5b192fd0c1b18 Can parse Bool, Word8, Word16 in big endian. Also parses Word32 in big endian if it fits into a Word16. Basic QuickCheck tests. ] hash: 0000011655-bbb603d639f2990239c94219ac21a3c7c77eddcacf8d99cb696b14eef9952687 [Add some utility functions, improve the test suite with some random tests Lennart Kolmodin **20100817193023 Ignore-this: 105b298324abf6bfc7929aea8b941646 ] hash: 0000005569-111f9d40d16aed19f90c0395a6ca5ce6466742149fd6c0e9fd0e726a62629a8f [Simple .cabal file, adding the QC tests as a test-suite Lennart Kolmodin **20100817193645 Ignore-this: ec689fa8a53894940714e9f9c6faff9e ] hash: 0000001329-f09ba91cee8767648603ea1bbda69bf2adbd00006203cc6b0623d7ad998a52f4 [Continue on the BitGet monad, and implement readWord64be Lennart Kolmodin **20100824180621 Ignore-this: 5ad2045c14802137698305f8e8129ff ] hash: 0000004465-602cf202a47a276147af1c23cda31ee00e9a40aecaa665574ff202991ad2961d [Two more QuickCheck tests Lennart Kolmodin **20100824180759 Ignore-this: 2bed8791e19a267e3d65a30576f1bd3c * Write a list of bools and read it back * Write a list of Word8s with variable numbers of bits, and read it back ] hash: 0000001269-cf313dd95bb3ad8def0fc1f80f086db5026aae3156b71489c78cc8510ac5fc5b [BitPut monad Lennart Kolmodin **20100824180859 Ignore-this: 8933b2936270146926ab2f31e8a30e82 ] hash: 0000002128-0d78a9bd35db8d2276ad9329704167668d2803c8bfa976c7f7bd8109100130f3 [Fix compile error in tests Lennart Kolmodin **20100824181410 Ignore-this: 13cee7ba4c2ba9558315b8d3bfc4efca ] hash: 0000000259-179723affa74045182cbcdb79c552c5f0b5f922acba9e8843db0c18d6194526a [Comment out the R structure, only monads left Lennart Kolmodin **20100824181529 Ignore-this: f92207b93c5ad23f0054d676ae06657 ] hash: 0000006744-384e43df625884659d65a2c60c879f5cb32f7469727bd0becc511c4f8d731aaf [runGetSimple: simply return the result value Lennart Kolmodin **20100826120817 Ignore-this: e9b94915ce5283bff2c8c62a3c2e1a57 ] hash: 0000000373-b199ca1fc5f9a1cd923231d010970d045f3d442978f34ebd73ffcdea5dea4a9c [Implement putWord16be Lennart Kolmodin **20100826120911 Ignore-this: c61fdaf4c64b4e0709640cdfbd55c4ed ] hash: 0000001159-d1764d818b37f7d17a23084ae7003e2e0a1dd52a4233d5ebb3fab9632abaf9a3 [Fix bug in getWord16be, found by QuickCheck Lennart Kolmodin **20100826131634 Ignore-this: 59381ffc0d2383fe8902794c8c0e5170 ] hash: 0000000932-69fd8eeb1cabc38b0343cfaf18be1a40e5e45104d41b706dc06d9a4c81bed2af [Reimplement some old tests Lennart Kolmodin **20100826131902 Ignore-this: e89363aea004d31cd9cd3afb1a20b6f8 Port from R structure to monads ] hash: 0000003924-a4e134067c77f8ecd450607b6de514f7ad121db38baf9f1822cdbe9951b05210 [Cleanup in tests Lennart Kolmodin **20100826132453 Ignore-this: 8b361ca186094c5cf4f925d303d16d9e ] hash: 0000002000-45bb4e17b13726deffa99fc0acccfdfa8cc7f80a805071bb60bd454934774a7c [Add module Bits, with BinaryBit class and instances Lennart Kolmodin **20100826144022 Ignore-this: 37bf652e6e2487bada645ed76303ddbc ] hash: 0000000706-3811c534114032bb7128d7398b2b5d5e6de73f0f143ffa366fb52c15861cdbf3 [Simplify tests by using the BinaryBit type class Lennart Kolmodin **20100826144105 Ignore-this: a1dc9fb880469114d5e35fa2bfd2e33c ] hash: 0000003023-6cabbb05e4a703242f32691d93b89567956162416e2c46f17b6beb1238f31906 [Add test to utility test functions Lennart Kolmodin **20100826144914 Ignore-this: 5b25e5208bdf880fd2a725613810fe70 ] hash: 0000000894-8d45b29ee7418414490456faa3ca71bb9199cf825ca8856f3af68bf484fa65ac [Add Setup.hs and LICENSE Lennart Kolmodin **20100826182836 Ignore-this: bad423271756d75122e7055e19c670b7 ] hash: 0000001808-d400d51c585ddcd51bbbf74bf673e87d92306169a4f9151563a50d73259a02d8 [Implement a shrinker for Word[8,16,32,64] Lennart Kolmodin **20100826183030 Ignore-this: 5670ef0b3fff0621e5f7822301ba0aba Works by trying to more intelligently shift and clear bits to make the numbers as small as possible. This is much faster than the old approach. ] hash: 0000001077-ce3e73b6844ecf54d83fc8e7574cd47e359d73829e19116ef634d66993d747b5 [Simple implementation of putWord32be Lennart Kolmodin **20100826195546 Ignore-this: 265d5268623a3b1992714e34af0ce566 ] hash: 0000000724-0cb56f178de6d6b14004d4a6d4296375e012bd0bf291296fc8bd6dbd3f7e5630 [Use test-framework to handles tests Lennart Kolmodin **20100826195627 Ignore-this: a364ba30980d2437f87a1d98c8e37e52 ] hash: 0000003298-9c844b1a41fbd665e5daaba0cded3dd3076dd09b6c6567f21afda039c884ccb6 [Add more tests Lennart Kolmodin **20100827130109 Ignore-this: ea61d28a808816ed17548799c4ed2949 - Compare the bitlevel get/put with a naive version that only gets/puts one bit at a time. - Compare the bitlevel get/put with the binary get/put for whole words. ] hash: 0000004782-64c03caa54e5448e2086a9b73828371caba2ceda0f97e4d93fd9b3a1c55d83ba [Reorder exports in BitGet and cleanup a bit Lennart Kolmodin **20100827130319 Ignore-this: 873d1a4a9adbc69d674f74dbd8c9c3d8 ] hash: 0000000697-21298f678cc52985304a61148c5b6f60db69163eab886551c82e827aa762c4c1 [Implement joinGet and joinPut Lennart Kolmodin **20100827130418 Ignore-this: 57ccfa7456ccf74c57c45f1b354662dc Allows to run the regular binary monads within the bitlevel monads. ] hash: 0000001224-a5f72fd6463c37ebb096f1c825bf01048673d1b02034c825cbaca8cf87ba827a [Implement putWord64be naively Lennart Kolmodin **20100827130632 Ignore-this: 32a1a2e9c9e62ec94e54f79425f51907 ] hash: 0000000398-bca21465c9cf7ba9110b23bc574c02d8fa367ea2f3ffaee7f2c7d5e7631dd8f5 [Use HPC for tests Lennart Kolmodin **20100827130654 Ignore-this: 6457576f417f1322fbbdf5868a0b2e8e ] hash: 0000000172-faf3c49de7095f903ef6a262a4d5789f3e86d95664062de458bdb0495d6c29bd [Enable get/putWord64be, add BinaryBit instance, enable tests Lennart Kolmodin **20100827142000 Ignore-this: 43dd8706c17e529d7dd1791c19e103a7 ] hash: 0000002249-004d01fb57f77f116f52be915521fe47c9c7edc06e31ea1f21646d5edee50c17 [Fix bug in getWord32be and getWord64be Lennart Kolmodin **20100827143558 Ignore-this: 7c561407d042aa891a43bbedb263dd78 ] hash: 0000000473-6984823c36780e30d6f5ee02d55e7aa258a40eb23ad9eede608af917ce2a5d56 [Don't need GADTs language extension any more Lennart Kolmodin **20100828161529 Ignore-this: 2c9620b4f1cd3a45bb1992753b032e8f ] hash: 0000000266-de049d60eee9dc4491cf4fd7e6f8c60f970cca94437611f2bff4fc54c941a9bf [Rename Lennart Kolmodin **20110526192245 Ignore-this: 38cf98b9efa8e6b1ddb7a2b2c96bda4b ] hash: 0000000963-3245b8c15baddded6e497f07d4931ad5cf17dfc4af01970da31298fa68ecb021 [Use default test-framework parameters, no override Lennart Kolmodin **20110601042633 Ignore-this: 4d0006cf9e1f421272dee4ccd43e6565 ] hash: 0000000677-03293844954b5b44fec4290da5214e5092a3f6e1721df8c22bcfe8cf62c27a65 [Override default QC 2.4 Arbitrary instance Lennart Kolmodin **20110601042824 Ignore-this: 9442bc168d4f6de583941657410cba33 In previous QC versions we had to declare our own instances of Arbitrary for Word8/Word16/Word32/Word64. This suited us well, as we want to implement our own shrinking method. In this patch we're working around these instances with the W datatype, a wrapper for the datatypes we're interested in. ] hash: 0000009558-eb8bf83e82195fad2171e44bdabb7e2117d38dbd4665aeae7056d8113b14d3de [Add type signatures for readWith(out)Offset Lennart Kolmodin **20110601043233 Ignore-this: 76c2cd71785ca1e5e74b034124c690b1 ] hash: 0000000410-09b0682bc1b124018a89d4a7c16e23f394965651c64452e2744befce5ae63986 [Disable joinGet Lennart Kolmodin **20110601044250 Ignore-this: 9f505f062af7a19878d6dc7e57f9a51 This feature relies on that you can take/set the internal state of the binary monad, something which we currently do not allow in the main branch. ] hash: 0000000386-91b6af1fcfa0c32d056bc4a701b01ccaeb4a37d2351c8af495b5400a210eb801 [test-suite stanza requires cabal 1.10 Lennart Kolmodin **20110601060539 Ignore-this: aa4807e69ed2ed14605190946fc6b776 ] hash: 0000000226-6d7f70fb4f1ee5512c09865cc97cc894fec452199db9b4425c6652a2c0291d7c [Comments. Lennart Kolmodin **20110601061149 Ignore-this: 4ba909667d68047789570d1288399db0 ] hash: 0000000256-e0e60fa3a888eb98742538a542bf3f5fe0866b3367eaea73d1d2283b31681002 [Make ensureBits pull just enough bytes from binary Lennart Kolmodin **20110601061303 Ignore-this: bd764f694858bc19dbf6b2f8f2b52ac3 Previously we let ensureBits take the internal state from binary (a bytestring chunk) but the master branch of binary does not allow this. Instead, read exactly as many bytes we need, each time we need something. ] hash: 0000001214-a598e52713ec30f59aca889f116131fcf39c7fd204b4fac2a81bc57598b898ab [Need to set default-language when forcing cabal-1.10 Lennart Kolmodin **20110601224443 Ignore-this: 5afe4316e5eec9343e8f228ebd972985 Setting it to Haskell98 ] hash: 0000000307-fe48a08cfaf6e76824b2bc093f8d58c64595c2070a889d1402c5b01d204e4dfa [Move into new module names Lennart Kolmodin **20110603213506 Ignore-this: eb597d6141868262ee67a0003293e78e ] hash: 0000000914-87ac7c7d5c8488f5dcf33a426c2cecbbc2c7de150bf28a3deaa4d68deafa5554 [Provide getByteString Lennart Kolmodin **20110603213552 Ignore-this: 18bcebf5ae470220cd829e8f1794d6fc ] hash: 0000000866-aff9eac87c9236ab80fe745a9d6cf00bc8c37438feb1c3397ddd8ea19dbde1de [Comment Lennart Kolmodin **20110605105602 Ignore-this: 3e6a02f7a5582d7209b8b2bb4acbc28a ] hash: 0000000233-bd394193826501a15544294acb4ce59f2443f222f8501609f7e06ba55876a5ad [Implement naive way to putByteString Lennart Kolmodin **20110605105611 Ignore-this: ab008186bd42032d32b33ec8ed36f4eb ] hash: 0000000498-0da5959a8e81aed8c0e8b7fc21bd6c49452ad7395fc176748fda1f82a8c5088e [Fix import of new namespace in QC tests Lennart Kolmodin **20110608191206 Ignore-this: 2e0c0a9d6f812d559fb03350f81b9004 ] hash: 0000000313-7ca1952ac7cb5a97d69efb7f49c09e484d09fcddc0bf826fc746ffb00c528555 [Remove error handling continuation. Lennart Kolmodin **20110930215741 Ignore-this: 92ee44d145df77a58b99ca69abeaf511 ] hash: 0000002498-1cb61da5ecb23fdb4f7f977ebcf4c74494ca91c848516762d6814a93e040ee2d [Simplify internal of monad, implement Applicative. Lennart Kolmodin **20111011202519 Ignore-this: 4286ba82c6ac8de8ff6b35dd9f61c449 Turned the monad into a simple state monad. Implemented a data type 'Block' which represents a block of data that is bounded in size and thus can be read with only one bound check. Implemented Applicative for the 'Block' data type. GHC is even clever enough to calculate the total size at compile time. Neat! Read Blocks with the new 'block' function. ] hash: 0000009311-3ab88d1110f4348cfe67e699fd95005deee205c8857157fb4ebf3ca68737123b [Add test to read ByteStrings that start with random offsets. Lennart Kolmodin **20111011203329 Ignore-this: 73d8b0a63a8d2535ba33783c7188960c Previously reading ByteStrings would always start at the next byte, ignoring any partial byte it might be processing. Last patch fixed this and allows reading at any offset without discarding any bits (although very expensive in CPU). This new test reads and writes ByteStrings interleaved with other random bits thus verifying this new functionality. ] hash: 0000002945-7b6e06996ddd564c0eb0e011079dfa322bfefc94dbdc6fc64839627fc7651a4f [Tidy up export declaration. Lennart Kolmodin **20111020082102 Ignore-this: 5fbd84ac6a219535f7f5655138643893 ] hash: 0000000377-514a3487dbd7cb3e0e28af3bd3fb9f4e603d654b43abc76fc3325d541a99a759 [Remove commented code (R structure). Lennart Kolmodin **20111020082132 Ignore-this: cf584877c35b33af6bf988dee980a0a6 ] hash: 0000002569-908211ede251cc8f105ca6ebad01607f44b60ad3aadc91a388276011161039c5 [Comments. Lennart Kolmodin **20111020082146 Ignore-this: e4b3ffe22bc3ea396f0f52bd3384fa3 ] hash: 0000000388-e2f3f6b96e5d5c1e6446999b2d226feb3f30b8bfeafaa86a4c57e6f373075a4c [Comments and haddock. Lennart Kolmodin **20111020210012 Ignore-this: d0f836af58ccd44e77b1b9bee2816f00 ] hash: 0000001461-217bca201db7a4589f2cf56a35d8554aa3414edd087ad57e5f0d4a1ddfa55859 [Export 'byteString'. Lennart Kolmodin **20111020210028 Ignore-this: db5bb3da2d5984dd6f0493ac9ed72cb2 ] hash: 0000000184-60d64b6be8d74315f53fbccf8112764d79d240718a6d6feda409d0ec1663f444 [Declare extensions in .cabal. Lennart Kolmodin **20111020210048 Ignore-this: 6d4004d89cffc4b8cc6729feecde7215 ] hash: 0000000329-e1340c166392fce13168816a59bc5c5d7b65636bee0270a4d6760ab107035854 [Export the Block datatype (but not its internals). Lennart Kolmodin **20111021211333 Ignore-this: 687b7cce27f396cb80530852f8a2acb7 ] hash: 0000000208-376e868c57f72c21d6807ba7c5c5ac5928948822d2fa22728f0995e2be95fd8d [Clean up test suite. Lennart Kolmodin **20111022104605 Ignore-this: 3522974198c8851ea1fb15fa91699803 ] hash: 0000001037-17a857afaafa6a7d2c1fda7424225a18bcfab878fb0b2d06b69bb9a0367b245d [Improve docs, fix -Wall and reorder code. Lennart Kolmodin **20111022104620 Ignore-this: ec8010d3512165b7855c1f118cd98771 ] hash: 0000012558-ccda117456430805931c0da58b974ad8dfc8b394195c79b087f4ef20cdf2940c [Use another version of BSD3 license file. Lennart Kolmodin **20111022104741 Ignore-this: 736ed4f3cc0da3483084061bcf650230 ] hash: 0000003094-67c10734fa33b1d0cef6c3b228410214e2ee822fc0a2b25111ae5dd5e753de10 [Update .cabal file. Add source-repository and better docs. Lennart Kolmodin **20111022113032 Ignore-this: 479ad890d9a59d3799a2bac6c7a3f0cd ] hash: 0000002024-05428f7e4246c557d0f5a354f9c0d6a989391f366bb51ab711b3b178efec1e29 [Add test for Applicative BitGet. Lennart Kolmodin **20111022113718 Ignore-this: 6e653d2ad5ccdd2d54a9de8d138f444f What's more interesting is Applicative Block, but we don't have a class for Block reads yet, so we can't make the test polymorphic. ] hash: 0000002440-493aee97b73ea9a911074dc14f3212bd3d4a4bf2e6070039af863671bd455757