1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
// https://stackoverflow.com/a/61417700
/*!
A Rust library to work with CPS (Composite Primitive Schema) data and parse it from and serialize
it to several binary and textual representation formats, such as YAML, JSON, and CBOR.
A useful side effect of this bi-direction is that Compris can be used to convert between these
formats.
What is CPS? It's the implicit, common data schema underlying these representation formats. It
comprises primitive data types (numbers, booleans, strings, etc.) as well as list and map
collection types, which enable a nested (recursive) structure. Hence it is "composite" (a.k.a.
"algebraic").
And yet despite being so widely used, CPS has been unnamed... until now. You're welcome.
CPS is sometimes glossed as "JSON", but that's misleading and ultimately unhelpful because JSON is
merely one representation format for the data, and is actually comparatively quite limited (e.g.
implementations do not often preserve the distinction between integers and floats). So instead of
saying "let's just store it as JSON", say "let's just store it as CPS", and use Compris to handle
the representation. It will allow you and your users to select from all supported formats at
runtime.
Compris is pronounced "com-PREE". The name comes from shortening CompositePrimitiveSchema to
ComPriS.
For more information and usage examples see the
[home page](https://github.com/tliron/compris).
J'ai compris!
*/
/// Annotate any type.
/// General-purpose serde deserialization using normal types as the intermediary.
/// Hints for extending representation formats (such as XJSON).
/// Iterate key-value pairs.
/// Normal types.
/// Parse various formats into normal types.
/// Path.
/// Resolve normal types into other types.
/// General-purpose serde serialization with enhanced support for normal types.
pub use *;