A binary serialization library https://github.com/GaloisInc/cereal

Version on this page:
LTS Haskell 9.14:
Stackage Nightly 2017-11-22:
Latest on Hackage:
BSD3 licensed by Lennart Kolmodin, Galois Inc., Lemmih, Bas van Dijk
Maintained by Trevor Elliott

Module documentation for

A binary serialization library, similar to binary, that introduces an isolate primitive for parser isolation, and labeled blocks for better error messages.


  • Implement the AMP recommended refactoring for the Functor/Applicative/Monad hierarchy for Get and PutM (thanks to Herbert Valerio Riedel!)
  • Unconditionally support GHC generics (thanks to Eric Mertens!)
  • Split the GSerialize class in two, to deal with a GHC bug (thanks Austin Seipp!)
  • No longer use Enum in the Serialize instance for Bool (thanks Francesco Mazzoli!)

  • Re-enable GHC.Generics support which was accidentally removed in

  • Switch to using the builder provided by the ByteString package
  • Change the encoding of Float and Double with the Serialize class to use the Data.Serialize.IEEE754 module
  • Add support for encoding and decoding ShortByteString
  • New and improved test suite thanks to Kei Hibino
  • Fix two bugs involving the lookAhead combinator and partial chunks.
Used by 324 packages:
accelerate-examples, accelerate-llvm-native, acid-state, acid-state-dist, adb, AES, aeson-serialize, alpha, apiary-authenticate, apiary-clientsession, approximate, arbb-vm, asn1-data, auto, automitive-cse, automotive-cse, aws, battleships, bayes-stack, bbi, BCMtools, bimaps, BiobaseBlast, BiobaseInfernal, BiobaseNewick, BiobaseTypes, BiobaseXNA, bitcoin-payment-channel, bitcoin-rpc, bitmaps, bittorrent, ble, blubber, blubber-server, bno055-haskell, bolt, bound, btree-concurrent, bytes, bytestring-typenats, cabal-sign, casadi-bindings, cassandra-cql, cassy, cereal-conduit, cereal-derive, cereal-enumerator, cereal-ieee754, cereal-io-streams, cereal-plus, cereal-streams, cereal-text, cereal-time, cereal-vector, cg, chatter, chevalier-common, cipher-aes128, clckwrks, clckwrks-plugin-bugs, clckwrks-plugin-media, clientsession, clifford, CMQ, codeworld-api, colada, combinator-interactive, Combinatorrent, commsec-keyexchange, compensated, continuum, continuum-client, courier, cql, cqrs-example, creatur, crypto-api, crypto-api-tests, crypto-conduit, cryptohash-cryptoapi, crypto-pubkey-openssh, crypto-totp, cube, daemons, data-embed, data-serializer, data-store, dbus, dclabel, debug-me, Delta-Lambda, dense, diagrams-lib, dib, DRBG, Dust, Dust-crypto, Dust-tools, Dust-tools-pcap, dynobud, eccrypto, edis, eventstore, exinst, existential, fb, fb-persistent, fibon, fixed-vector-cereal, fixfile, fluent-logger, forml, fpco-api, generic-accessors, genvalidity-hspec-cereal, geoip2, glabrous, goat, gore-and-ash-demo, gore-and-ash-sync, grenade, grid, hackage-mirror, hackage-server, hadoop-rpc, halfs, halvm-web, hans, happstack-clientsession, happstack-jmacro, haskdeep, haskell-modbus, haskell-mpi, haskell-openflow, haskell-tor, HaskellTorrent, haskoin-core, haskoin-node, haskoin-wallet, haskus-binary, hblock, hdph, hdph-closure, heatshrink, hecc, Hermes, hF2, hfsevents, HGamer3D, hGelf, higher-leveldb, himpy, histogram-fill-cereal, Hoed, hoodle-core, hoodle-types, Hs2lib, hscope, hs-multiaddr, hw-xml, hydrogen-prelude, hyperloglog, identifiers, ihaskell, intel-aes, ipython-kernel, jose-jwt, jupyter, kafka-client, kafka-device, kafka-device-joystick, kafka-device-spacenav, kyotocabinet, language-guess, libconfig, liblastfm, linear, LinguisticsTypes, liquid-fixpoint, liquidhaskell, llsd, llvm-pretty-bc-parser, locators, log-domain, LogicGrowsOnTrees, LogicGrowsOnTrees-MPI, LogicGrowsOnTrees-network, LogicGrowsOnTrees-processes, lua-bytecode, lz4, mediabus, mediabus-rtp, messagepack, messagepack-rpc, milena, minecraft-data, misfortune, modbus-tcp, monad-par-extras, monky, muesli, multiaddr, murmur3, MutationOrder, mysnapsession, nbt, neet, nehe-tuts, Neks, netlink, network-data, network-dns, network-stream, network-topic-models, network-transport-amqp, ntp-control, nvim-hs, objectid, one-time-password, openpgp-asciiarmor, openpgp-crypto-api, parallel-tasks, penny, penny-lib, periodic, persistent-cereal, persistent-mongoDB, pipes-cereal, Plot-ho-matic, ply-loader, pomodoro, powerqueue-distributed, powerqueue-levelmem, PrimitiveArray, property-list, prosper, protobuf, publicsuffixlist, punycode, pureMD5, push-notify, python-pickle, Quelea, raft, Rasenschach, rbpcp-api, restricted-workers, riemann, ripple, rpc, rtnetlink, ruby-marshal, ruin, safecopy, safecopy-migrate, safe-money, SciFlow, sde-solver, sdr, secp256k1, sentry, serialize-instances, serial-test-generators, servant-auth-cookie, servant-auth-hmac, serversession-backend-persistent, simple-tar, skein, snap, snaplet-auth-acid, snaplet-redis, snaplet-typed-sessions, socketson, socks, sousit, soyuz, spatial-math, special-keys, sphero, sprinkles, sproxy2, ssh, sssp, stable-tree, STL, stm-conduit, streaming-png, stunclient, SuffixStructures, SVGFonts, sync-mht, tables, tensorflow-records, test-sandbox, threefish, th-typegraph, tls, tripLL, Twofish, tx, type-cereal, udbus, uid, unbreak, userid, variation, vaultaire-common, vectortiles, vhd, vivid-osc, vivid-supercollider, wai-middleware-auth, wai-session-clientsession, wai-session-mysql, wai-session-postgresql, wai-session-tokyocabinet, wave, xenstore, xournal-types, yesod-core, yesod-platform, zigbee-znet25, zip, zip-conduit
comments powered byDisqus