From 2aea52d78f325f51d0153fde28ed26c39945d6d9 Mon Sep 17 00:00:00 2001 From: Alberto Restifo Date: Wed, 22 Apr 2020 22:31:00 +0200 Subject: [PATCH] Document limitations --- README.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/README.md b/README.md index 75d781d..b6791d3 100644 --- a/README.md +++ b/README.md @@ -5,6 +5,25 @@ This library implements the [RFC7049: Concise Binary Object Representation (CBOR)][rfc] in Crystal. +## Limitations + +### Maximum Array/String array/Bytes array length + +The spec allows for the maximum length of arrays, string arrays and bytes array +to be a `UInt64`. + +While this library supports lengths expressed as a `UInt64`, it must not exceed +`Int32::MAX`. + +### Diagnostic notation + +While this library implements a diagnostic notation to be able to run against +the examples provided in the RFC, the diagnostic notation is not fully +spec-compliant: + +- Indefinite length items are not marked with the starting underscore but + represented as their finite counterparts. + ## Installation 1. Add the dependency to your `shard.yml`: