diff options
author | Thiago de Arruda <tpadilha84@gmail.com> | 2014-09-11 21:56:52 -0300 |
---|---|---|
committer | Thiago de Arruda <tpadilha84@gmail.com> | 2014-09-12 13:50:07 -0300 |
commit | cd2e46c0785d40b9ea15f6d722a3fad54c007b9b (patch) | |
tree | 57503e18a1a685545750748b7fc854cb6ec85062 /src/nvim/os/msgpack_rpc.c | |
parent | 15ca58d79f8cc8565c1a2b2581029cf7901b5fbd (diff) | |
download | rneovim-cd2e46c0785d40b9ea15f6d722a3fad54c007b9b.tar.gz rneovim-cd2e46c0785d40b9ea15f6d722a3fad54c007b9b.tar.bz2 rneovim-cd2e46c0785d40b9ea15f6d722a3fad54c007b9b.zip |
api/msgpack-rpc: Refactor metadata object construction
Instead of building all metadata from msgpack-gen.lua, we now merge the
generated part with manual information(such as types and features). The metadata
is accessible through the api method `vim_get_api_info`.
This was done to simplify the generator while also increasing flexibility(by
being able to add more metadata)
Diffstat (limited to 'src/nvim/os/msgpack_rpc.c')
-rw-r--r-- | src/nvim/os/msgpack_rpc.c | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/src/nvim/os/msgpack_rpc.c b/src/nvim/os/msgpack_rpc.c index 2f347d9b15..d7e3d33c4b 100644 --- a/src/nvim/os/msgpack_rpc.c +++ b/src/nvim/os/msgpack_rpc.c @@ -17,8 +17,6 @@ # include "os/msgpack_rpc.c.generated.h" #endif -extern msgpack_unpacked msgpack_unpacked_metadata; - /// Validates the basic structure of the msgpack-rpc call and fills `res` /// with the basic response structure. /// @@ -83,19 +81,6 @@ Object msgpack_rpc_handle_missing_method(uint64_t channel_id, return NIL; } -/// Handler for retrieving API metadata through a msgpack-rpc call -Object msgpack_rpc_handle_get_api_metadata(uint64_t channel_id, - msgpack_object *req, - Error *error) -{ - Array rv = ARRAY_DICT_INIT; - Object metadata; - msgpack_rpc_to_object(&msgpack_unpacked_metadata.data, &metadata); - ADD(rv, INTEGER_OBJ((int64_t)channel_id)); - ADD(rv, metadata); - return ARRAY_OBJ(rv); -} - /// Serializes a msgpack-rpc request or notification(id == 0) WBuffer *serialize_request(uint64_t request_id, String method, |