{"id":16733133,"url":"https://github.com/quchen/binary-typed","last_synced_at":"2025-04-10T11:42:42.517Z","repository":{"id":56842938,"uuid":"20530639","full_name":"quchen/binary-typed","owner":"quchen","description":"Thin type-safe layer for the Haskell Binary library.","archived":false,"fork":false,"pushed_at":"2017-07-31T06:48:57.000Z","size":210,"stargazers_count":5,"open_issues_count":0,"forks_count":1,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-05-09T23:01:25.066Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Haskell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/quchen.png","metadata":{"files":{"readme":"README.md","changelog":"changelog.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-06-05T15:32:46.000Z","updated_at":"2019-12-05T06:33:26.000Z","dependencies_parsed_at":"2022-08-29T12:41:07.796Z","dependency_job_id":null,"html_url":"https://github.com/quchen/binary-typed","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quchen%2Fbinary-typed","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quchen%2Fbinary-typed/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quchen%2Fbinary-typed/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quchen%2Fbinary-typed/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/quchen","download_url":"https://codeload.github.com/quchen/binary-typed/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248211731,"owners_count":21065820,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-12T23:48:47.546Z","updated_at":"2025-04-10T11:42:42.498Z","avatar_url":"https://github.com/quchen.png","language":"Haskell","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![](https://travis-ci.org/quchen/binary-typed.png?branch=master)][travis]\n\n# Typed Binary lib\n\nStandard `Binary` serializes to `ByteString`, which is an untyped format;\ndeserialization of unexpected input usually results in unusable data.\n\nThis module is built around a `Typed` type, which allows serializing both a\nvalue and the type of that value; deserialization can then check whether the\nreceived data was sent assuming the right type, and error messages may provide\ninsight into the type mismatch.\n\nThis package serves the same purpose as [tagged-binary][tagged-binary], with\na couple of key differences:\n\n- Support of different kinds of serialized type annotations, each with\n  specific strengths and weaknesses.\n\n- Error messages can provide details on type errors at the cost of\n  longer message lengths to include the necessary information.\n\n- Very small performance overhead compared to using standard `Binary` due to\n  caching when using hashed type information. Since shown and full types are not\n  cached, decoding them has a significant performance hit (ballpark: factor of\n  two).\n\n- No depencency on `Internal` modules of other libraries, and a very small\n  dependency footprint in general.\n\nFor information about usage, see the `Tutorial` submodule.\n\nPerformance-wise, here is a value `Right (Left \u003c100 chars lipsum\u003e)` of\ntype `Either (Char, Int) (Either String (Maybe Integer))` benchmarked\nusing the `Hashed64` type representation:\n\n![](doc/bench-overview.png)\n\nMore information can be found on the [binary-typed Hackage page][hackage], or\nyou can generate the documentation yourself (via `cabal haddock`).\n\n\n[travis]: https://travis-ci.org/quchen/binary-typed\n[hackage]: http://hackage.haskell.org/package/binary-typed\n[tagged-binary]: http://hackage.haskell.org/package/tagged-binary","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fquchen%2Fbinary-typed","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fquchen%2Fbinary-typed","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fquchen%2Fbinary-typed/lists"}