nanorpc: magic library for a JSON-RPC 2.0 subset (WIP)
nanorpc implements a subset of JSON-RPC 2.0, notably with the lack of no-response "notifications" and lack of negative-value error codes.
The most interesting part of nanorpc is that it contains a derive macro, #[nanorpc], that given a trait that describes the server-side behavior of an RPC service, derives both raw JSON-RPC handlers and a client implementation:
// Autogenerates a server struct:
;
// Autogenerates a client struct like:
;
Note: right now the library is NOT done. Do not attempt to use it yet, the above is just a sketch of what it will do.