From 608f0e20a67ff68054f1c13f1db04a5553ed224b Mon Sep 17 00:00:00 2001 From: Michael Ilyin Date: Fri, 15 Nov 2024 11:59:25 +0100 Subject: [PATCH 1/6] members added to doc --- docs/api.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/api.rst b/docs/api.rst index 1cad3d826..787b62b3e 100644 --- a/docs/api.rst +++ b/docs/api.rst @@ -817,8 +817,11 @@ Types .. doxygenstruct:: zc_owned_liveliness_token_t .. doxygenstruct:: zc_liveliness_declaration_options_t + ::members: .. doxygenstruct:: zc_liveliness_get_options_t + ::members: .. doxygenstruct:: zc_liveliness_subscriber_options_t + ::members: Functions --------- From f98361d7b3a590800c054c5b5fa5154a8a485c5d Mon Sep 17 00:00:00 2001 From: Michael Ilyin Date: Fri, 15 Nov 2024 14:58:32 +0100 Subject: [PATCH 2/6] doc comment added --- src/liveliness.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/liveliness.rs b/src/liveliness.rs index 61641ab01..0e2c74caf 100644 --- a/src/liveliness.rs +++ b/src/liveliness.rs @@ -237,6 +237,7 @@ pub extern "C" fn zc_liveliness_declare_background_subscriber( /// @brief The options for `zc_liveliness_get()` #[repr(C)] pub struct zc_liveliness_get_options_t { + /// Set query timeout in milliseconds. timeout_ms: u32, } From 934fea0ef392fdeac137e622a43159362a0e721e Mon Sep 17 00:00:00 2001 From: Michael Ilyin Date: Fri, 15 Nov 2024 17:14:47 +0100 Subject: [PATCH 3/6] doc corrected, warning on build doc fixed --- docs/README.md | 1 + docs/api.rst | 6 +++--- include/zenoh_commons.h | 19 +++++++++++-------- src/liveliness.rs | 3 ++- src/shm/provider/alloc_layout.rs | 8 ++++---- src/shm/provider/shm_provider.rs | 8 ++++---- 6 files changed, 25 insertions(+), 20 deletions(-) diff --git a/docs/README.md b/docs/README.md index 41f1052cb..a20fc3892 100644 --- a/docs/README.md +++ b/docs/README.md @@ -6,6 +6,7 @@ zenoh-c API documentation is available on [Read the Docs](https://zenoh-c.readth ## How to build it ```bash +cargo check --all-features cd docs doxygen sphinx-build -b html . _build/html diff --git a/docs/api.rst b/docs/api.rst index 787b62b3e..44d24c71c 100644 --- a/docs/api.rst +++ b/docs/api.rst @@ -817,11 +817,11 @@ Types .. doxygenstruct:: zc_owned_liveliness_token_t .. doxygenstruct:: zc_liveliness_declaration_options_t - ::members: + :members: .. doxygenstruct:: zc_liveliness_get_options_t - ::members: + :members: .. doxygenstruct:: zc_liveliness_subscriber_options_t - ::members: + :members: Functions --------- diff --git a/include/zenoh_commons.h b/include/zenoh_commons.h index 09d6b862a..593c0c8b7 100644 --- a/include/zenoh_commons.h +++ b/include/zenoh_commons.h @@ -886,6 +886,9 @@ typedef struct zc_liveliness_subscriber_options_t { */ #if defined(Z_FEATURE_UNSTABLE_API) typedef struct zc_liveliness_get_options_t { + /** + * @brief Set query timeout in milliseconds. + */ uint32_t timeout_ms; } zc_liveliness_get_options_t; #endif @@ -1018,7 +1021,7 @@ void z_alloc_layout_alloc_gc(struct z_buf_alloc_result_t *out_result, #endif /** * @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. - * @brief Make allocation performing garbage collection and\or defragmentation if needed. + * @brief Make allocation performing garbage collection and/or defragmentation if needed. */ #if (defined(Z_FEATURE_SHARED_MEMORY) && defined(Z_FEATURE_UNSTABLE_API)) ZENOHC_API @@ -1027,7 +1030,7 @@ void z_alloc_layout_alloc_gc_defrag(struct z_buf_alloc_result_t *out_result, #endif /** * @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. - * @brief Make allocation performing garbage collection and\or defragmentation and\or blocking if needed. + * @brief Make allocation performing garbage collection and/or defragmentation and/or blocking if needed. */ #if (defined(Z_FEATURE_SHARED_MEMORY) && defined(Z_FEATURE_UNSTABLE_API)) ZENOHC_API @@ -1036,7 +1039,7 @@ void z_alloc_layout_alloc_gc_defrag_blocking(struct z_buf_alloc_result_t *out_re #endif /** * @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. - * @brief Make allocation performing garbage collection and\or defragmentation and\or forced deallocation if needed. + * @brief Make allocation performing garbage collection and/or defragmentation and/or forced deallocation if needed. */ #if (defined(Z_FEATURE_SHARED_MEMORY) && defined(Z_FEATURE_UNSTABLE_API)) ZENOHC_API @@ -1072,7 +1075,7 @@ z_result_t z_alloc_layout_new(struct z_owned_alloc_layout_t *this_, #endif /** * @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. - * @brief Make allocation performing garbage collection and\or defragmentation in async manner. Will return Z_EINVAL + * @brief Make allocation performing garbage collection and/or defragmentation in async manner. Will return Z_EINVAL * if used with non-threadsafe SHM Provider. */ #if (defined(Z_FEATURE_SHARED_MEMORY) && defined(Z_FEATURE_UNSTABLE_API)) @@ -3794,7 +3797,7 @@ void z_shm_provider_alloc_gc(struct z_buf_layout_alloc_result_t *out_result, #endif /** * @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. - * @brief Make allocation performing garbage collection and\or defragmentation if needed. + * @brief Make allocation performing garbage collection and/or defragmentation if needed. */ #if (defined(Z_FEATURE_SHARED_MEMORY) && defined(Z_FEATURE_UNSTABLE_API)) ZENOHC_API @@ -3805,7 +3808,7 @@ void z_shm_provider_alloc_gc_defrag(struct z_buf_layout_alloc_result_t *out_resu #endif /** * @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. - * @brief Make allocation performing garbage collection and\or defragmentation in async manner. Will return Z_EINVAL + * @brief Make allocation performing garbage collection and/or defragmentation in async manner. Will return Z_EINVAL * if used with non-threadsafe SHM Provider. */ #if (defined(Z_FEATURE_SHARED_MEMORY) && defined(Z_FEATURE_UNSTABLE_API)) @@ -3820,7 +3823,7 @@ z_result_t z_shm_provider_alloc_gc_defrag_async(struct z_buf_layout_alloc_result #endif /** * @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. - * @brief Make allocation performing garbage collection and\or defragmentation and\or blocking if needed. + * @brief Make allocation performing garbage collection and/or defragmentation and/or blocking if needed. */ #if (defined(Z_FEATURE_SHARED_MEMORY) && defined(Z_FEATURE_UNSTABLE_API)) ZENOHC_API @@ -3831,7 +3834,7 @@ void z_shm_provider_alloc_gc_defrag_blocking(struct z_buf_layout_alloc_result_t #endif /** * @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. - * @brief Make allocation performing garbage collection and\or defragmentation and\or forced deallocation if needed. + * @brief Make allocation performing garbage collection and/or defragmentation and/or forced deallocation if needed. */ #if (defined(Z_FEATURE_SHARED_MEMORY) && defined(Z_FEATURE_UNSTABLE_API)) ZENOHC_API diff --git a/src/liveliness.rs b/src/liveliness.rs index 0e2c74caf..e8038822f 100644 --- a/src/liveliness.rs +++ b/src/liveliness.rs @@ -138,6 +138,7 @@ pub extern "C" fn zc_liveliness_undeclare_token( /// @brief The options for `zc_liveliness_declare_subscriber()` #[repr(C)] pub struct zc_liveliness_subscriber_options_t { + /// Receive liveliness tokens that were declared before this liveliness subscriber. history: bool, } @@ -238,7 +239,7 @@ pub extern "C" fn zc_liveliness_declare_background_subscriber( #[repr(C)] pub struct zc_liveliness_get_options_t { /// Set query timeout in milliseconds. - timeout_ms: u32, + pub timeout_ms: u32, } /// @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. diff --git a/src/shm/provider/alloc_layout.rs b/src/shm/provider/alloc_layout.rs index 37349afa5..0682471da 100644 --- a/src/shm/provider/alloc_layout.rs +++ b/src/shm/provider/alloc_layout.rs @@ -117,7 +117,7 @@ pub extern "C" fn z_alloc_layout_alloc_gc( } /// @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. -/// @brief Make allocation performing garbage collection and\or defragmentation if needed. +/// @brief Make allocation performing garbage collection and/or defragmentation if needed. #[no_mangle] pub extern "C" fn z_alloc_layout_alloc_gc_defrag( out_result: &mut MaybeUninit, @@ -127,7 +127,7 @@ pub extern "C" fn z_alloc_layout_alloc_gc_defrag( } /// @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. -/// @brief Make allocation performing garbage collection and\or defragmentation and\or forced deallocation if needed. +/// @brief Make allocation performing garbage collection and/or defragmentation and/or forced deallocation if needed. #[no_mangle] pub extern "C" fn z_alloc_layout_alloc_gc_defrag_dealloc( out_result: &mut MaybeUninit, @@ -137,7 +137,7 @@ pub extern "C" fn z_alloc_layout_alloc_gc_defrag_dealloc( } /// @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. -/// @brief Make allocation performing garbage collection and\or defragmentation and\or blocking if needed. +/// @brief Make allocation performing garbage collection and/or defragmentation and/or blocking if needed. #[no_mangle] pub extern "C" fn z_alloc_layout_alloc_gc_defrag_blocking( out_result: &mut MaybeUninit, @@ -147,7 +147,7 @@ pub extern "C" fn z_alloc_layout_alloc_gc_defrag_blocking( } /// @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. -/// @brief Make allocation performing garbage collection and\or defragmentation in async manner. Will return Z_EINVAL +/// @brief Make allocation performing garbage collection and/or defragmentation in async manner. Will return Z_EINVAL /// if used with non-threadsafe SHM Provider. #[no_mangle] pub extern "C" fn z_alloc_layout_threadsafe_alloc_gc_defrag_async( diff --git a/src/shm/provider/shm_provider.rs b/src/shm/provider/shm_provider.rs index 7c4ec19ed..f518b8c0e 100644 --- a/src/shm/provider/shm_provider.rs +++ b/src/shm/provider/shm_provider.rs @@ -154,7 +154,7 @@ pub extern "C" fn z_shm_provider_alloc_gc( } /// @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. -/// @brief Make allocation performing garbage collection and\or defragmentation if needed. +/// @brief Make allocation performing garbage collection and/or defragmentation if needed. #[no_mangle] pub extern "C" fn z_shm_provider_alloc_gc_defrag( out_result: &mut MaybeUninit, @@ -166,7 +166,7 @@ pub extern "C" fn z_shm_provider_alloc_gc_defrag( } /// @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. -/// @brief Make allocation performing garbage collection and\or defragmentation and\or forced deallocation if needed. +/// @brief Make allocation performing garbage collection and/or defragmentation and/or forced deallocation if needed. #[no_mangle] pub extern "C" fn z_shm_provider_alloc_gc_defrag_dealloc( out_result: &mut MaybeUninit, @@ -178,7 +178,7 @@ pub extern "C" fn z_shm_provider_alloc_gc_defrag_dealloc( } /// @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. -/// @brief Make allocation performing garbage collection and\or defragmentation and\or blocking if needed. +/// @brief Make allocation performing garbage collection and/or defragmentation and/or blocking if needed. #[no_mangle] pub extern "C" fn z_shm_provider_alloc_gc_defrag_blocking( out_result: &mut MaybeUninit, @@ -190,7 +190,7 @@ pub extern "C" fn z_shm_provider_alloc_gc_defrag_blocking( } /// @warning This API has been marked as unstable: it works as advertised, but it may be changed in a future release. -/// @brief Make allocation performing garbage collection and\or defragmentation in async manner. Will return Z_EINVAL +/// @brief Make allocation performing garbage collection and/or defragmentation in async manner. Will return Z_EINVAL /// if used with non-threadsafe SHM Provider. #[no_mangle] pub extern "C" fn z_shm_provider_alloc_gc_defrag_async( From cfc4128d95e133f9fd7c1985abf38714317d012d Mon Sep 17 00:00:00 2001 From: Michael Ilyin Date: Tue, 3 Dec 2024 10:53:43 +0100 Subject: [PATCH 4/6] macro header update --- include/zenoh_macros.h | 317 +---------------------------------------- 1 file changed, 2 insertions(+), 315 deletions(-) diff --git a/include/zenoh_macros.h b/include/zenoh_macros.h index eccc03a77..e03ca9db1 100644 --- a/include/zenoh_macros.h +++ b/include/zenoh_macros.h @@ -4,10 +4,8 @@ #ifndef __cplusplus -static inline z_moved_alloc_layout_t* z_alloc_layout_move(z_owned_alloc_layout_t* x) { return (z_moved_alloc_layout_t*)(x); } static inline z_moved_bytes_t* z_bytes_move(z_owned_bytes_t* x) { return (z_moved_bytes_t*)(x); } static inline z_moved_bytes_writer_t* z_bytes_writer_move(z_owned_bytes_writer_t* x) { return (z_moved_bytes_writer_t*)(x); } -static inline z_moved_chunk_alloc_result_t* z_chunk_alloc_result_move(z_owned_chunk_alloc_result_t* x) { return (z_moved_chunk_alloc_result_t*)(x); } static inline z_moved_closure_hello_t* z_closure_hello_move(z_owned_closure_hello_t* x) { return (z_moved_closure_hello_t*)(x); } static inline z_moved_closure_query_t* z_closure_query_move(z_owned_closure_query_t* x) { return (z_moved_closure_query_t*)(x); } static inline z_moved_closure_reply_t* z_closure_reply_move(z_owned_closure_reply_t* x) { return (z_moved_closure_reply_t*)(x); } @@ -21,8 +19,6 @@ static inline z_moved_fifo_handler_reply_t* z_fifo_handler_reply_move(z_owned_fi static inline z_moved_fifo_handler_sample_t* z_fifo_handler_sample_move(z_owned_fifo_handler_sample_t* x) { return (z_moved_fifo_handler_sample_t*)(x); } static inline z_moved_hello_t* z_hello_move(z_owned_hello_t* x) { return (z_moved_hello_t*)(x); } static inline z_moved_keyexpr_t* z_keyexpr_move(z_owned_keyexpr_t* x) { return (z_moved_keyexpr_t*)(x); } -static inline z_moved_liveliness_token_t* z_liveliness_token_move(z_owned_liveliness_token_t* x) { return (z_moved_liveliness_token_t*)(x); } -static inline z_moved_memory_layout_t* z_memory_layout_move(z_owned_memory_layout_t* x) { return (z_moved_memory_layout_t*)(x); } static inline z_moved_mutex_t* z_mutex_move(z_owned_mutex_t* x) { return (z_moved_mutex_t*)(x); } static inline z_moved_publisher_t* z_publisher_move(z_owned_publisher_t* x) { return (z_moved_publisher_t*)(x); } static inline z_moved_query_t* z_query_move(z_owned_query_t* x) { return (z_moved_query_t*)(x); } @@ -34,29 +30,17 @@ static inline z_moved_ring_handler_reply_t* z_ring_handler_reply_move(z_owned_ri static inline z_moved_ring_handler_sample_t* z_ring_handler_sample_move(z_owned_ring_handler_sample_t* x) { return (z_moved_ring_handler_sample_t*)(x); } static inline z_moved_sample_t* z_sample_move(z_owned_sample_t* x) { return (z_moved_sample_t*)(x); } static inline z_moved_session_t* z_session_move(z_owned_session_t* x) { return (z_moved_session_t*)(x); } -static inline z_moved_shm_client_t* z_shm_client_move(z_owned_shm_client_t* x) { return (z_moved_shm_client_t*)(x); } -static inline z_moved_shm_client_storage_t* z_shm_client_storage_move(z_owned_shm_client_storage_t* x) { return (z_moved_shm_client_storage_t*)(x); } -static inline z_moved_shm_t* z_shm_move(z_owned_shm_t* x) { return (z_moved_shm_t*)(x); } -static inline z_moved_shm_mut_t* z_shm_mut_move(z_owned_shm_mut_t* x) { return (z_moved_shm_mut_t*)(x); } -static inline z_moved_shm_provider_t* z_shm_provider_move(z_owned_shm_provider_t* x) { return (z_moved_shm_provider_t*)(x); } static inline z_moved_slice_t* z_slice_move(z_owned_slice_t* x) { return (z_moved_slice_t*)(x); } -static inline z_moved_source_info_t* z_source_info_move(z_owned_source_info_t* x) { return (z_moved_source_info_t*)(x); } static inline z_moved_string_array_t* z_string_array_move(z_owned_string_array_t* x) { return (z_moved_string_array_t*)(x); } static inline z_moved_string_t* z_string_move(z_owned_string_t* x) { return (z_moved_string_t*)(x); } static inline z_moved_subscriber_t* z_subscriber_move(z_owned_subscriber_t* x) { return (z_moved_subscriber_t*)(x); } static inline z_moved_task_t* z_task_move(z_owned_task_t* x) { return (z_moved_task_t*)(x); } static inline zc_moved_closure_log_t* zc_closure_log_move(zc_owned_closure_log_t* x) { return (zc_moved_closure_log_t*)(x); } -static inline zc_moved_closure_matching_status_t* zc_closure_matching_status_move(zc_owned_closure_matching_status_t* x) { return (zc_moved_closure_matching_status_t*)(x); } -static inline zc_moved_matching_listener_t* zc_publisher_matching_listener_move(zc_owned_matching_listener_t* x) { return (zc_moved_matching_listener_t*)(x); } -static inline zc_moved_shm_client_list_t* zc_shm_client_list_move(zc_owned_shm_client_list_t* x) { return (zc_moved_shm_client_list_t*)(x); } -static inline ze_moved_publication_cache_t* ze_publication_cache_move(ze_owned_publication_cache_t* x) { return (ze_moved_publication_cache_t*)(x); } -static inline ze_moved_querying_subscriber_t* ze_querying_subscriber_move(ze_owned_querying_subscriber_t* x) { return (ze_moved_querying_subscriber_t*)(x); } static inline ze_moved_serializer_t* ze_serializer_move(ze_owned_serializer_t* x) { return (ze_moved_serializer_t*)(x); } #define z_loan(this_) \ _Generic((this_), \ - z_owned_alloc_layout_t : z_alloc_layout_loan, \ z_owned_bytes_t : z_bytes_loan, \ z_owned_bytes_writer_t : z_bytes_writer_loan, \ z_owned_closure_hello_t : z_closure_hello_loan, \ @@ -72,8 +56,6 @@ static inline ze_moved_serializer_t* ze_serializer_move(ze_owned_serializer_t* x z_owned_fifo_handler_sample_t : z_fifo_handler_sample_loan, \ z_owned_hello_t : z_hello_loan, \ z_owned_keyexpr_t : z_keyexpr_loan, \ - z_owned_liveliness_token_t : z_liveliness_token_loan, \ - z_owned_memory_layout_t : z_memory_layout_loan, \ z_owned_publisher_t : z_publisher_loan, \ z_owned_query_t : z_query_loan, \ z_owned_queryable_t : z_queryable_loan, \ @@ -84,12 +66,7 @@ static inline ze_moved_serializer_t* ze_serializer_move(ze_owned_serializer_t* x z_owned_ring_handler_sample_t : z_ring_handler_sample_loan, \ z_owned_sample_t : z_sample_loan, \ z_owned_session_t : z_session_loan, \ - z_owned_shm_client_storage_t : z_shm_client_storage_loan, \ - z_owned_shm_t : z_shm_loan, \ - z_owned_shm_mut_t : z_shm_mut_loan, \ - z_owned_shm_provider_t : z_shm_provider_loan, \ z_owned_slice_t : z_slice_loan, \ - z_owned_source_info_t : z_source_info_loan, \ z_owned_string_array_t : z_string_array_loan, \ z_owned_string_t : z_string_loan, \ z_owned_subscriber_t : z_subscriber_loan, \ @@ -97,10 +74,6 @@ static inline ze_moved_serializer_t* ze_serializer_move(ze_owned_serializer_t* x z_view_slice_t : z_view_slice_loan, \ z_view_string_t : z_view_string_loan, \ zc_owned_closure_log_t : zc_closure_log_loan, \ - zc_owned_closure_matching_status_t : zc_closure_matching_status_loan, \ - zc_owned_shm_client_list_t : zc_shm_client_list_loan, \ - ze_owned_publication_cache_t : ze_publication_cache_loan, \ - ze_owned_querying_subscriber_t : ze_querying_subscriber_loan, \ ze_owned_serializer_t : ze_serializer_loan \ )(&this_) @@ -118,19 +91,14 @@ static inline ze_moved_serializer_t* ze_serializer_move(ze_owned_serializer_t* x z_owned_mutex_t : z_mutex_loan_mut, \ z_owned_publisher_t : z_publisher_loan_mut, \ z_owned_session_t : z_session_loan_mut, \ - z_owned_shm_t : z_shm_loan_mut, \ - z_owned_shm_mut_t : z_shm_mut_loan_mut, \ z_owned_string_array_t : z_string_array_loan_mut, \ - zc_owned_shm_client_list_t : zc_shm_client_list_loan_mut, \ ze_owned_serializer_t : ze_serializer_loan_mut \ )(&this_) #define z_drop(this_) \ _Generic((this_), \ - z_moved_alloc_layout_t* : z_alloc_layout_drop, \ z_moved_bytes_t* : z_bytes_drop, \ z_moved_bytes_writer_t* : z_bytes_writer_drop, \ - z_moved_chunk_alloc_result_t* : z_chunk_alloc_result_drop, \ z_moved_closure_hello_t* : z_closure_hello_drop, \ z_moved_closure_query_t* : z_closure_query_drop, \ z_moved_closure_reply_t* : z_closure_reply_drop, \ @@ -144,8 +112,6 @@ static inline ze_moved_serializer_t* ze_serializer_move(ze_owned_serializer_t* x z_moved_fifo_handler_sample_t* : z_fifo_handler_sample_drop, \ z_moved_hello_t* : z_hello_drop, \ z_moved_keyexpr_t* : z_keyexpr_drop, \ - z_moved_liveliness_token_t* : z_liveliness_token_drop, \ - z_moved_memory_layout_t* : z_memory_layout_drop, \ z_moved_mutex_t* : z_mutex_drop, \ z_moved_publisher_t* : z_publisher_drop, \ z_moved_query_t* : z_query_drop, \ @@ -157,32 +123,19 @@ static inline ze_moved_serializer_t* ze_serializer_move(ze_owned_serializer_t* x z_moved_ring_handler_sample_t* : z_ring_handler_sample_drop, \ z_moved_sample_t* : z_sample_drop, \ z_moved_session_t* : z_session_drop, \ - z_moved_shm_client_t* : z_shm_client_drop, \ - z_moved_shm_client_storage_t* : z_shm_client_storage_drop, \ - z_moved_shm_t* : z_shm_drop, \ - z_moved_shm_mut_t* : z_shm_mut_drop, \ - z_moved_shm_provider_t* : z_shm_provider_drop, \ z_moved_slice_t* : z_slice_drop, \ - z_moved_source_info_t* : z_source_info_drop, \ z_moved_string_array_t* : z_string_array_drop, \ z_moved_string_t* : z_string_drop, \ z_moved_subscriber_t* : z_subscriber_drop, \ z_moved_task_t* : z_task_drop, \ zc_moved_closure_log_t* : zc_closure_log_drop, \ - zc_moved_closure_matching_status_t* : zc_closure_matching_status_drop, \ - zc_moved_matching_listener_t* : zc_publisher_matching_listener_drop, \ - zc_moved_shm_client_list_t* : zc_shm_client_list_drop, \ - ze_moved_publication_cache_t* : ze_publication_cache_drop, \ - ze_moved_querying_subscriber_t* : ze_querying_subscriber_drop, \ ze_moved_serializer_t* : ze_serializer_drop \ )(this_) #define z_move(this_) \ _Generic((this_), \ - z_owned_alloc_layout_t : z_alloc_layout_move, \ z_owned_bytes_t : z_bytes_move, \ z_owned_bytes_writer_t : z_bytes_writer_move, \ - z_owned_chunk_alloc_result_t : z_chunk_alloc_result_move, \ z_owned_closure_hello_t : z_closure_hello_move, \ z_owned_closure_query_t : z_closure_query_move, \ z_owned_closure_reply_t : z_closure_reply_move, \ @@ -196,8 +149,6 @@ static inline ze_moved_serializer_t* ze_serializer_move(ze_owned_serializer_t* x z_owned_fifo_handler_sample_t : z_fifo_handler_sample_move, \ z_owned_hello_t : z_hello_move, \ z_owned_keyexpr_t : z_keyexpr_move, \ - z_owned_liveliness_token_t : z_liveliness_token_move, \ - z_owned_memory_layout_t : z_memory_layout_move, \ z_owned_mutex_t : z_mutex_move, \ z_owned_publisher_t : z_publisher_move, \ z_owned_query_t : z_query_move, \ @@ -209,32 +160,19 @@ static inline ze_moved_serializer_t* ze_serializer_move(ze_owned_serializer_t* x z_owned_ring_handler_sample_t : z_ring_handler_sample_move, \ z_owned_sample_t : z_sample_move, \ z_owned_session_t : z_session_move, \ - z_owned_shm_client_t : z_shm_client_move, \ - z_owned_shm_client_storage_t : z_shm_client_storage_move, \ - z_owned_shm_t : z_shm_move, \ - z_owned_shm_mut_t : z_shm_mut_move, \ - z_owned_shm_provider_t : z_shm_provider_move, \ z_owned_slice_t : z_slice_move, \ - z_owned_source_info_t : z_source_info_move, \ z_owned_string_array_t : z_string_array_move, \ z_owned_string_t : z_string_move, \ z_owned_subscriber_t : z_subscriber_move, \ z_owned_task_t : z_task_move, \ zc_owned_closure_log_t : zc_closure_log_move, \ - zc_owned_closure_matching_status_t : zc_closure_matching_status_move, \ - zc_owned_matching_listener_t : zc_publisher_matching_listener_move, \ - zc_owned_shm_client_list_t : zc_shm_client_list_move, \ - ze_owned_publication_cache_t : ze_publication_cache_move, \ - ze_owned_querying_subscriber_t : ze_querying_subscriber_move, \ ze_owned_serializer_t : ze_serializer_move \ )(&this_) #define z_internal_null(this_) \ _Generic((this_), \ - z_owned_alloc_layout_t* : z_internal_alloc_layout_null, \ z_owned_bytes_t* : z_internal_bytes_null, \ z_owned_bytes_writer_t* : z_internal_bytes_writer_null, \ - z_owned_chunk_alloc_result_t* : z_internal_chunk_alloc_result_null, \ z_owned_closure_hello_t* : z_internal_closure_hello_null, \ z_owned_closure_query_t* : z_internal_closure_query_null, \ z_owned_closure_reply_t* : z_internal_closure_reply_null, \ @@ -248,8 +186,6 @@ static inline ze_moved_serializer_t* ze_serializer_move(ze_owned_serializer_t* x z_owned_fifo_handler_sample_t* : z_internal_fifo_handler_sample_null, \ z_owned_hello_t* : z_internal_hello_null, \ z_owned_keyexpr_t* : z_internal_keyexpr_null, \ - z_owned_liveliness_token_t* : z_internal_liveliness_token_null, \ - z_owned_memory_layout_t* : z_internal_memory_layout_null, \ z_owned_mutex_t* : z_internal_mutex_null, \ z_owned_publisher_t* : z_internal_publisher_null, \ z_owned_query_t* : z_internal_query_null, \ @@ -261,30 +197,17 @@ static inline ze_moved_serializer_t* ze_serializer_move(ze_owned_serializer_t* x z_owned_ring_handler_sample_t* : z_internal_ring_handler_sample_null, \ z_owned_sample_t* : z_internal_sample_null, \ z_owned_session_t* : z_internal_session_null, \ - z_owned_shm_client_t* : z_internal_shm_client_null, \ - z_owned_shm_client_storage_t* : z_internal_shm_client_storage_null, \ - z_owned_shm_mut_t* : z_internal_shm_mut_null, \ - z_owned_shm_t* : z_internal_shm_null, \ - z_owned_shm_provider_t* : z_internal_shm_provider_null, \ z_owned_slice_t* : z_internal_slice_null, \ - z_owned_source_info_t* : z_internal_source_info_null, \ z_owned_string_array_t* : z_internal_string_array_null, \ z_owned_string_t* : z_internal_string_null, \ z_owned_subscriber_t* : z_internal_subscriber_null, \ z_owned_task_t* : z_internal_task_null, \ zc_owned_closure_log_t* : zc_internal_closure_log_null, \ - zc_owned_closure_matching_status_t* : zc_internal_closure_matching_status_null, \ - zc_owned_matching_listener_t* : zc_internal_matching_listener_null, \ - zc_owned_shm_client_list_t* : zc_internal_shm_client_list_null, \ - ze_owned_publication_cache_t* : ze_internal_publication_cache_null, \ - ze_owned_querying_subscriber_t* : ze_internal_querying_subscriber_null, \ ze_owned_serializer_t* : ze_internal_serializer_null \ )(this_) -static inline void z_alloc_layout_take(z_owned_alloc_layout_t* this_, z_moved_alloc_layout_t* x) { *this_ = x->_this; z_internal_alloc_layout_null(&x->_this); } static inline void z_bytes_take(z_owned_bytes_t* this_, z_moved_bytes_t* x) { *this_ = x->_this; z_internal_bytes_null(&x->_this); } static inline void z_bytes_writer_take(z_owned_bytes_writer_t* this_, z_moved_bytes_writer_t* x) { *this_ = x->_this; z_internal_bytes_writer_null(&x->_this); } -static inline void z_chunk_alloc_result_take(z_owned_chunk_alloc_result_t* this_, z_moved_chunk_alloc_result_t* x) { *this_ = x->_this; z_internal_chunk_alloc_result_null(&x->_this); } static inline void z_closure_hello_take(z_owned_closure_hello_t* this_, z_moved_closure_hello_t* x) { *this_ = x->_this; z_internal_closure_hello_null(&x->_this); } static inline void z_closure_query_take(z_owned_closure_query_t* closure_, z_moved_closure_query_t* x) { *closure_ = x->_this; z_internal_closure_query_null(&x->_this); } static inline void z_closure_reply_take(z_owned_closure_reply_t* closure_, z_moved_closure_reply_t* x) { *closure_ = x->_this; z_internal_closure_reply_null(&x->_this); } @@ -298,8 +221,6 @@ static inline void z_fifo_handler_reply_take(z_owned_fifo_handler_reply_t* this_ static inline void z_fifo_handler_sample_take(z_owned_fifo_handler_sample_t* this_, z_moved_fifo_handler_sample_t* x) { *this_ = x->_this; z_internal_fifo_handler_sample_null(&x->_this); } static inline void z_hello_take(z_owned_hello_t* this_, z_moved_hello_t* x) { *this_ = x->_this; z_internal_hello_null(&x->_this); } static inline void z_keyexpr_take(z_owned_keyexpr_t* this_, z_moved_keyexpr_t* x) { *this_ = x->_this; z_internal_keyexpr_null(&x->_this); } -static inline void z_liveliness_token_take(z_owned_liveliness_token_t* this_, z_moved_liveliness_token_t* x) { *this_ = x->_this; z_internal_liveliness_token_null(&x->_this); } -static inline void z_memory_layout_take(z_owned_memory_layout_t* this_, z_moved_memory_layout_t* x) { *this_ = x->_this; z_internal_memory_layout_null(&x->_this); } static inline void z_mutex_take(z_owned_mutex_t* this_, z_moved_mutex_t* x) { *this_ = x->_this; z_internal_mutex_null(&x->_this); } static inline void z_publisher_take(z_owned_publisher_t* this_, z_moved_publisher_t* x) { *this_ = x->_this; z_internal_publisher_null(&x->_this); } static inline void z_query_take(z_owned_query_t* this_, z_moved_query_t* x) { *this_ = x->_this; z_internal_query_null(&x->_this); } @@ -311,32 +232,19 @@ static inline void z_ring_handler_reply_take(z_owned_ring_handler_reply_t* this_ static inline void z_ring_handler_sample_take(z_owned_ring_handler_sample_t* this_, z_moved_ring_handler_sample_t* x) { *this_ = x->_this; z_internal_ring_handler_sample_null(&x->_this); } static inline void z_sample_take(z_owned_sample_t* this_, z_moved_sample_t* x) { *this_ = x->_this; z_internal_sample_null(&x->_this); } static inline void z_session_take(z_owned_session_t* this_, z_moved_session_t* x) { *this_ = x->_this; z_internal_session_null(&x->_this); } -static inline void z_shm_client_take(z_owned_shm_client_t* this_, z_moved_shm_client_t* x) { *this_ = x->_this; z_internal_shm_client_null(&x->_this); } -static inline void z_shm_client_storage_take(z_owned_shm_client_storage_t* this_, z_moved_shm_client_storage_t* x) { *this_ = x->_this; z_internal_shm_client_storage_null(&x->_this); } -static inline void z_shm_take(z_owned_shm_t* this_, z_moved_shm_t* x) { *this_ = x->_this; z_internal_shm_null(&x->_this); } -static inline void z_shm_mut_take(z_owned_shm_mut_t* this_, z_moved_shm_mut_t* x) { *this_ = x->_this; z_internal_shm_mut_null(&x->_this); } -static inline void z_shm_provider_take(z_owned_shm_provider_t* this_, z_moved_shm_provider_t* x) { *this_ = x->_this; z_internal_shm_provider_null(&x->_this); } static inline void z_slice_take(z_owned_slice_t* this_, z_moved_slice_t* x) { *this_ = x->_this; z_internal_slice_null(&x->_this); } -static inline void z_source_info_take(z_owned_source_info_t* this_, z_moved_source_info_t* x) { *this_ = x->_this; z_internal_source_info_null(&x->_this); } static inline void z_string_array_take(z_owned_string_array_t* this_, z_moved_string_array_t* x) { *this_ = x->_this; z_internal_string_array_null(&x->_this); } static inline void z_string_take(z_owned_string_t* this_, z_moved_string_t* x) { *this_ = x->_this; z_internal_string_null(&x->_this); } static inline void z_subscriber_take(z_owned_subscriber_t* this_, z_moved_subscriber_t* x) { *this_ = x->_this; z_internal_subscriber_null(&x->_this); } static inline void z_task_take(z_owned_task_t* this_, z_moved_task_t* x) { *this_ = x->_this; z_internal_task_null(&x->_this); } static inline void zc_closure_log_take(zc_owned_closure_log_t* closure_, zc_moved_closure_log_t* x) { *closure_ = x->_this; zc_internal_closure_log_null(&x->_this); } -static inline void zc_closure_matching_status_take(zc_owned_closure_matching_status_t* closure_, zc_moved_closure_matching_status_t* x) { *closure_ = x->_this; zc_internal_closure_matching_status_null(&x->_this); } -static inline void zc_publisher_matching_listener_take(zc_owned_matching_listener_t* this_, zc_moved_matching_listener_t* x) { *this_ = x->_this; zc_internal_matching_listener_null(&x->_this); } -static inline void zc_shm_client_list_take(zc_owned_shm_client_list_t* this_, zc_moved_shm_client_list_t* x) { *this_ = x->_this; zc_internal_shm_client_list_null(&x->_this); } -static inline void ze_publication_cache_take(ze_owned_publication_cache_t* this_, ze_moved_publication_cache_t* x) { *this_ = x->_this; ze_internal_publication_cache_null(&x->_this); } -static inline void ze_querying_subscriber_take(ze_owned_querying_subscriber_t* this_, ze_moved_querying_subscriber_t* x) { *this_ = x->_this; ze_internal_querying_subscriber_null(&x->_this); } static inline void ze_serializer_take(ze_owned_serializer_t* this_, ze_moved_serializer_t* x) { *this_ = x->_this; ze_internal_serializer_null(&x->_this); } #define z_take(this_, x) \ _Generic((this_), \ - z_owned_alloc_layout_t* : z_alloc_layout_take, \ z_owned_bytes_t* : z_bytes_take, \ z_owned_bytes_writer_t* : z_bytes_writer_take, \ - z_owned_chunk_alloc_result_t* : z_chunk_alloc_result_take, \ z_owned_closure_hello_t* : z_closure_hello_take, \ z_owned_closure_query_t* : z_closure_query_take, \ z_owned_closure_reply_t* : z_closure_reply_take, \ @@ -350,8 +258,6 @@ static inline void ze_serializer_take(ze_owned_serializer_t* this_, ze_moved_ser z_owned_fifo_handler_sample_t* : z_fifo_handler_sample_take, \ z_owned_hello_t* : z_hello_take, \ z_owned_keyexpr_t* : z_keyexpr_take, \ - z_owned_liveliness_token_t* : z_liveliness_token_take, \ - z_owned_memory_layout_t* : z_memory_layout_take, \ z_owned_mutex_t* : z_mutex_take, \ z_owned_publisher_t* : z_publisher_take, \ z_owned_query_t* : z_query_take, \ @@ -363,32 +269,19 @@ static inline void ze_serializer_take(ze_owned_serializer_t* this_, ze_moved_ser z_owned_ring_handler_sample_t* : z_ring_handler_sample_take, \ z_owned_sample_t* : z_sample_take, \ z_owned_session_t* : z_session_take, \ - z_owned_shm_client_t* : z_shm_client_take, \ - z_owned_shm_client_storage_t* : z_shm_client_storage_take, \ - z_owned_shm_t* : z_shm_take, \ - z_owned_shm_mut_t* : z_shm_mut_take, \ - z_owned_shm_provider_t* : z_shm_provider_take, \ z_owned_slice_t* : z_slice_take, \ - z_owned_source_info_t* : z_source_info_take, \ z_owned_string_array_t* : z_string_array_take, \ z_owned_string_t* : z_string_take, \ z_owned_subscriber_t* : z_subscriber_take, \ z_owned_task_t* : z_task_take, \ zc_owned_closure_log_t* : zc_closure_log_take, \ - zc_owned_closure_matching_status_t* : zc_closure_matching_status_take, \ - zc_owned_matching_listener_t* : zc_publisher_matching_listener_take, \ - zc_owned_shm_client_list_t* : zc_shm_client_list_take, \ - ze_owned_publication_cache_t* : ze_publication_cache_take, \ - ze_owned_querying_subscriber_t* : ze_querying_subscriber_take, \ ze_owned_serializer_t* : ze_serializer_take \ )(this_, x) #define z_internal_check(this_) \ _Generic((this_), \ - z_owned_alloc_layout_t : z_internal_alloc_layout_check, \ z_owned_bytes_t : z_internal_bytes_check, \ z_owned_bytes_writer_t : z_internal_bytes_writer_check, \ - z_owned_chunk_alloc_result_t : z_internal_chunk_alloc_result_check, \ z_owned_closure_hello_t : z_internal_closure_hello_check, \ z_owned_closure_query_t : z_internal_closure_query_check, \ z_owned_closure_reply_t : z_internal_closure_reply_check, \ @@ -402,8 +295,6 @@ static inline void ze_serializer_take(ze_owned_serializer_t* this_, ze_moved_ser z_owned_fifo_handler_sample_t : z_internal_fifo_handler_sample_check, \ z_owned_hello_t : z_internal_hello_check, \ z_owned_keyexpr_t : z_internal_keyexpr_check, \ - z_owned_liveliness_token_t : z_internal_liveliness_token_check, \ - z_owned_memory_layout_t : z_internal_memory_layout_check, \ z_owned_mutex_t : z_internal_mutex_check, \ z_owned_publisher_t : z_internal_publisher_check, \ z_owned_query_t : z_internal_query_check, \ @@ -415,23 +306,12 @@ static inline void ze_serializer_take(ze_owned_serializer_t* this_, ze_moved_ser z_owned_ring_handler_sample_t : z_internal_ring_handler_sample_check, \ z_owned_sample_t : z_internal_sample_check, \ z_owned_session_t : z_internal_session_check, \ - z_owned_shm_t : z_internal_shm_check, \ - z_owned_shm_client_t : z_internal_shm_client_check, \ - z_owned_shm_client_storage_t : z_internal_shm_client_storage_check, \ - z_owned_shm_mut_t : z_internal_shm_mut_check, \ - z_owned_shm_provider_t : z_internal_shm_provider_check, \ z_owned_slice_t : z_internal_slice_check, \ - z_owned_source_info_t : z_internal_source_info_check, \ z_owned_string_array_t : z_internal_string_array_check, \ z_owned_string_t : z_internal_string_check, \ z_owned_subscriber_t : z_internal_subscriber_check, \ z_owned_task_t : z_internal_task_check, \ zc_owned_closure_log_t : zc_internal_closure_log_check, \ - zc_owned_closure_matching_status_t : zc_internal_closure_matching_status_check, \ - zc_owned_matching_listener_t : zc_internal_matching_listener_check, \ - zc_owned_shm_client_list_t : zc_internal_shm_client_list_check, \ - ze_owned_publication_cache_t : ze_internal_publication_cache_check, \ - ze_owned_querying_subscriber_t : ze_internal_querying_subscriber_check, \ ze_owned_serializer_t : ze_internal_serializer_check \ )(&this_) @@ -441,8 +321,7 @@ static inline void ze_serializer_take(ze_owned_serializer_t* this_, ze_moved_ser const z_loaned_closure_query_t* : z_closure_query_call, \ const z_loaned_closure_reply_t* : z_closure_reply_call, \ const z_loaned_closure_sample_t* : z_closure_sample_call, \ - const z_loaned_closure_zid_t* : z_closure_zid_call, \ - const zc_loaned_closure_matching_status_t* : zc_closure_matching_status_call \ + const z_loaned_closure_zid_t* : z_closure_zid_call \ )(closure, hello) typedef void(*z_closure_drop_callback_t)(void *context); @@ -452,7 +331,6 @@ typedef void(*z_closure_reply_callback_t)(z_loaned_reply_t *reply, void *context typedef void(*z_closure_sample_callback_t)(z_loaned_sample_t *sample, void *context); typedef void(*z_closure_zid_callback_t)(const z_id_t *z_id, void *context); typedef void(*zc_closure_log_callback_t)(zc_log_severity_t severity, const z_loaned_string_t *msg, void *context); -typedef void(*zc_closure_matching_status_callback_t)(const zc_matching_status_t *matching_status, void *context); #define z_closure(this_, call, drop, context) \ _Generic((this_), \ @@ -461,8 +339,7 @@ typedef void(*zc_closure_matching_status_callback_t)(const zc_matching_status_t z_owned_closure_reply_t* : z_closure_reply, \ z_owned_closure_sample_t* : z_closure_sample, \ z_owned_closure_zid_t* : z_closure_zid, \ - zc_owned_closure_log_t* : zc_closure_log, \ - zc_owned_closure_matching_status_t* : zc_closure_matching_status \ + zc_owned_closure_log_t* : zc_closure_log \ )(this_, call, drop, context) #define z_try_recv(this_, query) \ @@ -496,8 +373,6 @@ typedef void(*zc_closure_matching_status_callback_t)(const zc_matching_status_t z_owned_reply_t* : z_reply_clone, \ z_owned_reply_err_t* : z_reply_err_clone, \ z_owned_sample_t* : z_sample_clone, \ - z_owned_shm_client_storage_t* : z_shm_client_storage_clone, \ - z_owned_shm_t* : z_shm_clone, \ z_owned_slice_t* : z_slice_clone, \ z_owned_string_array_t* : z_string_array_clone, \ z_owned_string_t* : z_string_clone \ @@ -505,10 +380,8 @@ typedef void(*zc_closure_matching_status_callback_t)(const zc_matching_status_t #else // #ifndef __cplusplus -static inline z_moved_alloc_layout_t* z_alloc_layout_move(z_owned_alloc_layout_t* x) { return reinterpret_cast(x); } static inline z_moved_bytes_t* z_bytes_move(z_owned_bytes_t* x) { return reinterpret_cast(x); } static inline z_moved_bytes_writer_t* z_bytes_writer_move(z_owned_bytes_writer_t* x) { return reinterpret_cast(x); } -static inline z_moved_chunk_alloc_result_t* z_chunk_alloc_result_move(z_owned_chunk_alloc_result_t* x) { return reinterpret_cast(x); } static inline z_moved_closure_hello_t* z_closure_hello_move(z_owned_closure_hello_t* x) { return reinterpret_cast(x); } static inline z_moved_closure_query_t* z_closure_query_move(z_owned_closure_query_t* x) { return reinterpret_cast(x); } static inline z_moved_closure_reply_t* z_closure_reply_move(z_owned_closure_reply_t* x) { return reinterpret_cast(x); } @@ -522,8 +395,6 @@ static inline z_moved_fifo_handler_reply_t* z_fifo_handler_reply_move(z_owned_fi static inline z_moved_fifo_handler_sample_t* z_fifo_handler_sample_move(z_owned_fifo_handler_sample_t* x) { return reinterpret_cast(x); } static inline z_moved_hello_t* z_hello_move(z_owned_hello_t* x) { return reinterpret_cast(x); } static inline z_moved_keyexpr_t* z_keyexpr_move(z_owned_keyexpr_t* x) { return reinterpret_cast(x); } -static inline z_moved_liveliness_token_t* z_liveliness_token_move(z_owned_liveliness_token_t* x) { return reinterpret_cast(x); } -static inline z_moved_memory_layout_t* z_memory_layout_move(z_owned_memory_layout_t* x) { return reinterpret_cast(x); } static inline z_moved_mutex_t* z_mutex_move(z_owned_mutex_t* x) { return reinterpret_cast(x); } static inline z_moved_publisher_t* z_publisher_move(z_owned_publisher_t* x) { return reinterpret_cast(x); } static inline z_moved_query_t* z_query_move(z_owned_query_t* x) { return reinterpret_cast(x); } @@ -535,28 +406,16 @@ static inline z_moved_ring_handler_reply_t* z_ring_handler_reply_move(z_owned_ri static inline z_moved_ring_handler_sample_t* z_ring_handler_sample_move(z_owned_ring_handler_sample_t* x) { return reinterpret_cast(x); } static inline z_moved_sample_t* z_sample_move(z_owned_sample_t* x) { return reinterpret_cast(x); } static inline z_moved_session_t* z_session_move(z_owned_session_t* x) { return reinterpret_cast(x); } -static inline z_moved_shm_client_t* z_shm_client_move(z_owned_shm_client_t* x) { return reinterpret_cast(x); } -static inline z_moved_shm_client_storage_t* z_shm_client_storage_move(z_owned_shm_client_storage_t* x) { return reinterpret_cast(x); } -static inline z_moved_shm_t* z_shm_move(z_owned_shm_t* x) { return reinterpret_cast(x); } -static inline z_moved_shm_mut_t* z_shm_mut_move(z_owned_shm_mut_t* x) { return reinterpret_cast(x); } -static inline z_moved_shm_provider_t* z_shm_provider_move(z_owned_shm_provider_t* x) { return reinterpret_cast(x); } static inline z_moved_slice_t* z_slice_move(z_owned_slice_t* x) { return reinterpret_cast(x); } -static inline z_moved_source_info_t* z_source_info_move(z_owned_source_info_t* x) { return reinterpret_cast(x); } static inline z_moved_string_array_t* z_string_array_move(z_owned_string_array_t* x) { return reinterpret_cast(x); } static inline z_moved_string_t* z_string_move(z_owned_string_t* x) { return reinterpret_cast(x); } static inline z_moved_subscriber_t* z_subscriber_move(z_owned_subscriber_t* x) { return reinterpret_cast(x); } static inline z_moved_task_t* z_task_move(z_owned_task_t* x) { return reinterpret_cast(x); } static inline zc_moved_closure_log_t* zc_closure_log_move(zc_owned_closure_log_t* x) { return reinterpret_cast(x); } -static inline zc_moved_closure_matching_status_t* zc_closure_matching_status_move(zc_owned_closure_matching_status_t* x) { return reinterpret_cast(x); } -static inline zc_moved_matching_listener_t* zc_publisher_matching_listener_move(zc_owned_matching_listener_t* x) { return reinterpret_cast(x); } -static inline zc_moved_shm_client_list_t* zc_shm_client_list_move(zc_owned_shm_client_list_t* x) { return reinterpret_cast(x); } -static inline ze_moved_publication_cache_t* ze_publication_cache_move(ze_owned_publication_cache_t* x) { return reinterpret_cast(x); } -static inline ze_moved_querying_subscriber_t* ze_querying_subscriber_move(ze_owned_querying_subscriber_t* x) { return reinterpret_cast(x); } static inline ze_moved_serializer_t* ze_serializer_move(ze_owned_serializer_t* x) { return reinterpret_cast(x); } -inline const z_loaned_alloc_layout_t* z_loan(const z_owned_alloc_layout_t& this_) { return z_alloc_layout_loan(&this_); }; inline const z_loaned_bytes_t* z_loan(const z_owned_bytes_t& this_) { return z_bytes_loan(&this_); }; inline const z_loaned_bytes_writer_t* z_loan(const z_owned_bytes_writer_t& this_) { return z_bytes_writer_loan(&this_); }; inline const z_loaned_closure_hello_t* z_loan(const z_owned_closure_hello_t& closure) { return z_closure_hello_loan(&closure); }; @@ -572,8 +431,6 @@ inline const z_loaned_fifo_handler_reply_t* z_loan(const z_owned_fifo_handler_re inline const z_loaned_fifo_handler_sample_t* z_loan(const z_owned_fifo_handler_sample_t& this_) { return z_fifo_handler_sample_loan(&this_); }; inline const z_loaned_hello_t* z_loan(const z_owned_hello_t& this_) { return z_hello_loan(&this_); }; inline const z_loaned_keyexpr_t* z_loan(const z_owned_keyexpr_t& this_) { return z_keyexpr_loan(&this_); }; -inline const z_loaned_liveliness_token_t* z_loan(const z_owned_liveliness_token_t& this_) { return z_liveliness_token_loan(&this_); }; -inline const z_loaned_memory_layout_t* z_loan(const z_owned_memory_layout_t& this_) { return z_memory_layout_loan(&this_); }; inline const z_loaned_publisher_t* z_loan(const z_owned_publisher_t& this_) { return z_publisher_loan(&this_); }; inline const z_loaned_query_t* z_loan(const z_owned_query_t& this_) { return z_query_loan(&this_); }; inline const z_loaned_queryable_t* z_loan(const z_owned_queryable_t& this_) { return z_queryable_loan(&this_); }; @@ -584,12 +441,7 @@ inline const z_loaned_ring_handler_reply_t* z_loan(const z_owned_ring_handler_re inline const z_loaned_ring_handler_sample_t* z_loan(const z_owned_ring_handler_sample_t& this_) { return z_ring_handler_sample_loan(&this_); }; inline const z_loaned_sample_t* z_loan(const z_owned_sample_t& this_) { return z_sample_loan(&this_); }; inline const z_loaned_session_t* z_loan(const z_owned_session_t& this_) { return z_session_loan(&this_); }; -inline const z_loaned_shm_client_storage_t* z_loan(const z_owned_shm_client_storage_t& this_) { return z_shm_client_storage_loan(&this_); }; -inline const z_loaned_shm_t* z_loan(const z_owned_shm_t& this_) { return z_shm_loan(&this_); }; -inline const z_loaned_shm_mut_t* z_loan(const z_owned_shm_mut_t& this_) { return z_shm_mut_loan(&this_); }; -inline const z_loaned_shm_provider_t* z_loan(const z_owned_shm_provider_t& this_) { return z_shm_provider_loan(&this_); }; inline const z_loaned_slice_t* z_loan(const z_owned_slice_t& this_) { return z_slice_loan(&this_); }; -inline const z_loaned_source_info_t* z_loan(const z_owned_source_info_t& this_) { return z_source_info_loan(&this_); }; inline const z_loaned_string_array_t* z_loan(const z_owned_string_array_t& this_) { return z_string_array_loan(&this_); }; inline const z_loaned_string_t* z_loan(const z_owned_string_t& this_) { return z_string_loan(&this_); }; inline const z_loaned_subscriber_t* z_loan(const z_owned_subscriber_t& this_) { return z_subscriber_loan(&this_); }; @@ -597,10 +449,6 @@ inline const z_loaned_keyexpr_t* z_loan(const z_view_keyexpr_t& this_) { return inline const z_loaned_slice_t* z_loan(const z_view_slice_t& this_) { return z_view_slice_loan(&this_); }; inline const z_loaned_string_t* z_loan(const z_view_string_t& this_) { return z_view_string_loan(&this_); }; inline const zc_loaned_closure_log_t* z_loan(const zc_owned_closure_log_t& closure) { return zc_closure_log_loan(&closure); }; -inline const zc_loaned_closure_matching_status_t* z_loan(const zc_owned_closure_matching_status_t& closure) { return zc_closure_matching_status_loan(&closure); }; -inline const zc_loaned_shm_client_list_t* z_loan(const zc_owned_shm_client_list_t& this_) { return zc_shm_client_list_loan(&this_); }; -inline const ze_loaned_publication_cache_t* z_loan(const ze_owned_publication_cache_t& this_) { return ze_publication_cache_loan(&this_); }; -inline const ze_loaned_querying_subscriber_t* z_loan(const ze_owned_querying_subscriber_t& this_) { return ze_querying_subscriber_loan(&this_); }; inline const ze_loaned_serializer_t* z_loan(const ze_owned_serializer_t& this_) { return ze_serializer_loan(&this_); }; @@ -616,17 +464,12 @@ inline z_loaned_encoding_t* z_loan_mut(z_owned_encoding_t& this_) { return z_enc inline z_loaned_mutex_t* z_loan_mut(z_owned_mutex_t& this_) { return z_mutex_loan_mut(&this_); }; inline z_loaned_publisher_t* z_loan_mut(z_owned_publisher_t& this_) { return z_publisher_loan_mut(&this_); }; inline z_loaned_session_t* z_loan_mut(z_owned_session_t& this_) { return z_session_loan_mut(&this_); }; -inline z_loaned_shm_t* z_loan_mut(z_owned_shm_t& this_) { return z_shm_loan_mut(&this_); }; -inline z_loaned_shm_mut_t* z_loan_mut(z_owned_shm_mut_t& this_) { return z_shm_mut_loan_mut(&this_); }; inline z_loaned_string_array_t* z_loan_mut(z_owned_string_array_t& this_) { return z_string_array_loan_mut(&this_); }; -inline zc_loaned_shm_client_list_t* z_loan_mut(zc_owned_shm_client_list_t& this_) { return zc_shm_client_list_loan_mut(&this_); }; inline ze_loaned_serializer_t* z_loan_mut(ze_owned_serializer_t& this_) { return ze_serializer_loan_mut(&this_); }; -inline void z_drop(z_moved_alloc_layout_t* this_) { z_alloc_layout_drop(this_); }; inline void z_drop(z_moved_bytes_t* this_) { z_bytes_drop(this_); }; inline void z_drop(z_moved_bytes_writer_t* this_) { z_bytes_writer_drop(this_); }; -inline void z_drop(z_moved_chunk_alloc_result_t* this_) { z_chunk_alloc_result_drop(this_); }; inline void z_drop(z_moved_closure_hello_t* this_) { z_closure_hello_drop(this_); }; inline void z_drop(z_moved_closure_query_t* closure_) { z_closure_query_drop(closure_); }; inline void z_drop(z_moved_closure_reply_t* closure_) { z_closure_reply_drop(closure_); }; @@ -640,8 +483,6 @@ inline void z_drop(z_moved_fifo_handler_reply_t* this_) { z_fifo_handler_reply_d inline void z_drop(z_moved_fifo_handler_sample_t* this_) { z_fifo_handler_sample_drop(this_); }; inline void z_drop(z_moved_hello_t* this_) { z_hello_drop(this_); }; inline void z_drop(z_moved_keyexpr_t* this_) { z_keyexpr_drop(this_); }; -inline void z_drop(z_moved_liveliness_token_t* this_) { z_liveliness_token_drop(this_); }; -inline void z_drop(z_moved_memory_layout_t* this_) { z_memory_layout_drop(this_); }; inline void z_drop(z_moved_mutex_t* this_) { z_mutex_drop(this_); }; inline void z_drop(z_moved_publisher_t* this_) { z_publisher_drop(this_); }; inline void z_drop(z_moved_query_t* this_) { z_query_drop(this_); }; @@ -653,30 +494,17 @@ inline void z_drop(z_moved_ring_handler_reply_t* this_) { z_ring_handler_reply_d inline void z_drop(z_moved_ring_handler_sample_t* this_) { z_ring_handler_sample_drop(this_); }; inline void z_drop(z_moved_sample_t* this_) { z_sample_drop(this_); }; inline void z_drop(z_moved_session_t* this_) { z_session_drop(this_); }; -inline void z_drop(z_moved_shm_client_t* this_) { z_shm_client_drop(this_); }; -inline void z_drop(z_moved_shm_client_storage_t* this_) { z_shm_client_storage_drop(this_); }; -inline void z_drop(z_moved_shm_t* this_) { z_shm_drop(this_); }; -inline void z_drop(z_moved_shm_mut_t* this_) { z_shm_mut_drop(this_); }; -inline void z_drop(z_moved_shm_provider_t* this_) { z_shm_provider_drop(this_); }; inline void z_drop(z_moved_slice_t* this_) { z_slice_drop(this_); }; -inline void z_drop(z_moved_source_info_t* this_) { z_source_info_drop(this_); }; inline void z_drop(z_moved_string_array_t* this_) { z_string_array_drop(this_); }; inline void z_drop(z_moved_string_t* this_) { z_string_drop(this_); }; inline void z_drop(z_moved_subscriber_t* this_) { z_subscriber_drop(this_); }; inline void z_drop(z_moved_task_t* this_) { z_task_drop(this_); }; inline void z_drop(zc_moved_closure_log_t* closure_) { zc_closure_log_drop(closure_); }; -inline void z_drop(zc_moved_closure_matching_status_t* closure_) { zc_closure_matching_status_drop(closure_); }; -inline void z_drop(zc_moved_matching_listener_t* this_) { zc_publisher_matching_listener_drop(this_); }; -inline void z_drop(zc_moved_shm_client_list_t* this_) { zc_shm_client_list_drop(this_); }; -inline void z_drop(ze_moved_publication_cache_t* this_) { ze_publication_cache_drop(this_); }; -inline void z_drop(ze_moved_querying_subscriber_t* this_) { ze_querying_subscriber_drop(this_); }; inline void z_drop(ze_moved_serializer_t* this_) { ze_serializer_drop(this_); }; -inline z_moved_alloc_layout_t* z_move(z_owned_alloc_layout_t& this_) { return z_alloc_layout_move(&this_); }; inline z_moved_bytes_t* z_move(z_owned_bytes_t& this_) { return z_bytes_move(&this_); }; inline z_moved_bytes_writer_t* z_move(z_owned_bytes_writer_t& this_) { return z_bytes_writer_move(&this_); }; -inline z_moved_chunk_alloc_result_t* z_move(z_owned_chunk_alloc_result_t& this_) { return z_chunk_alloc_result_move(&this_); }; inline z_moved_closure_hello_t* z_move(z_owned_closure_hello_t& this_) { return z_closure_hello_move(&this_); }; inline z_moved_closure_query_t* z_move(z_owned_closure_query_t& closure_) { return z_closure_query_move(&closure_); }; inline z_moved_closure_reply_t* z_move(z_owned_closure_reply_t& closure_) { return z_closure_reply_move(&closure_); }; @@ -690,8 +518,6 @@ inline z_moved_fifo_handler_reply_t* z_move(z_owned_fifo_handler_reply_t& this_) inline z_moved_fifo_handler_sample_t* z_move(z_owned_fifo_handler_sample_t& this_) { return z_fifo_handler_sample_move(&this_); }; inline z_moved_hello_t* z_move(z_owned_hello_t& this_) { return z_hello_move(&this_); }; inline z_moved_keyexpr_t* z_move(z_owned_keyexpr_t& this_) { return z_keyexpr_move(&this_); }; -inline z_moved_liveliness_token_t* z_move(z_owned_liveliness_token_t& this_) { return z_liveliness_token_move(&this_); }; -inline z_moved_memory_layout_t* z_move(z_owned_memory_layout_t& this_) { return z_memory_layout_move(&this_); }; inline z_moved_mutex_t* z_move(z_owned_mutex_t& this_) { return z_mutex_move(&this_); }; inline z_moved_publisher_t* z_move(z_owned_publisher_t& this_) { return z_publisher_move(&this_); }; inline z_moved_query_t* z_move(z_owned_query_t& this_) { return z_query_move(&this_); }; @@ -703,30 +529,17 @@ inline z_moved_ring_handler_reply_t* z_move(z_owned_ring_handler_reply_t& this_) inline z_moved_ring_handler_sample_t* z_move(z_owned_ring_handler_sample_t& this_) { return z_ring_handler_sample_move(&this_); }; inline z_moved_sample_t* z_move(z_owned_sample_t& this_) { return z_sample_move(&this_); }; inline z_moved_session_t* z_move(z_owned_session_t& this_) { return z_session_move(&this_); }; -inline z_moved_shm_client_t* z_move(z_owned_shm_client_t& this_) { return z_shm_client_move(&this_); }; -inline z_moved_shm_client_storage_t* z_move(z_owned_shm_client_storage_t& this_) { return z_shm_client_storage_move(&this_); }; -inline z_moved_shm_t* z_move(z_owned_shm_t& this_) { return z_shm_move(&this_); }; -inline z_moved_shm_mut_t* z_move(z_owned_shm_mut_t& this_) { return z_shm_mut_move(&this_); }; -inline z_moved_shm_provider_t* z_move(z_owned_shm_provider_t& this_) { return z_shm_provider_move(&this_); }; inline z_moved_slice_t* z_move(z_owned_slice_t& this_) { return z_slice_move(&this_); }; -inline z_moved_source_info_t* z_move(z_owned_source_info_t& this_) { return z_source_info_move(&this_); }; inline z_moved_string_array_t* z_move(z_owned_string_array_t& this_) { return z_string_array_move(&this_); }; inline z_moved_string_t* z_move(z_owned_string_t& this_) { return z_string_move(&this_); }; inline z_moved_subscriber_t* z_move(z_owned_subscriber_t& this_) { return z_subscriber_move(&this_); }; inline z_moved_task_t* z_move(z_owned_task_t& this_) { return z_task_move(&this_); }; inline zc_moved_closure_log_t* z_move(zc_owned_closure_log_t& closure_) { return zc_closure_log_move(&closure_); }; -inline zc_moved_closure_matching_status_t* z_move(zc_owned_closure_matching_status_t& closure_) { return zc_closure_matching_status_move(&closure_); }; -inline zc_moved_matching_listener_t* z_move(zc_owned_matching_listener_t& this_) { return zc_publisher_matching_listener_move(&this_); }; -inline zc_moved_shm_client_list_t* z_move(zc_owned_shm_client_list_t& this_) { return zc_shm_client_list_move(&this_); }; -inline ze_moved_publication_cache_t* z_move(ze_owned_publication_cache_t& this_) { return ze_publication_cache_move(&this_); }; -inline ze_moved_querying_subscriber_t* z_move(ze_owned_querying_subscriber_t& this_) { return ze_querying_subscriber_move(&this_); }; inline ze_moved_serializer_t* z_move(ze_owned_serializer_t& this_) { return ze_serializer_move(&this_); }; -inline void z_internal_null(z_owned_alloc_layout_t* this_) { z_internal_alloc_layout_null(this_); }; inline void z_internal_null(z_owned_bytes_t* this_) { z_internal_bytes_null(this_); }; inline void z_internal_null(z_owned_bytes_writer_t* this_) { z_internal_bytes_writer_null(this_); }; -inline void z_internal_null(z_owned_chunk_alloc_result_t* this_) { z_internal_chunk_alloc_result_null(this_); }; inline void z_internal_null(z_owned_closure_hello_t* this_) { z_internal_closure_hello_null(this_); }; inline void z_internal_null(z_owned_closure_query_t* this_) { z_internal_closure_query_null(this_); }; inline void z_internal_null(z_owned_closure_reply_t* this_) { z_internal_closure_reply_null(this_); }; @@ -740,8 +553,6 @@ inline void z_internal_null(z_owned_fifo_handler_reply_t* this_) { z_internal_fi inline void z_internal_null(z_owned_fifo_handler_sample_t* this_) { z_internal_fifo_handler_sample_null(this_); }; inline void z_internal_null(z_owned_hello_t* this_) { z_internal_hello_null(this_); }; inline void z_internal_null(z_owned_keyexpr_t* this_) { z_internal_keyexpr_null(this_); }; -inline void z_internal_null(z_owned_liveliness_token_t* this_) { z_internal_liveliness_token_null(this_); }; -inline void z_internal_null(z_owned_memory_layout_t* this_) { z_internal_memory_layout_null(this_); }; inline void z_internal_null(z_owned_mutex_t* this_) { z_internal_mutex_null(this_); }; inline void z_internal_null(z_owned_publisher_t* this_) { z_internal_publisher_null(this_); }; inline void z_internal_null(z_owned_query_t* this_) { z_internal_query_null(this_); }; @@ -753,29 +564,16 @@ inline void z_internal_null(z_owned_ring_handler_reply_t* this_) { z_internal_ri inline void z_internal_null(z_owned_ring_handler_sample_t* this_) { z_internal_ring_handler_sample_null(this_); }; inline void z_internal_null(z_owned_sample_t* this_) { z_internal_sample_null(this_); }; inline void z_internal_null(z_owned_session_t* this_) { z_internal_session_null(this_); }; -inline void z_internal_null(z_owned_shm_client_t* this_) { z_internal_shm_client_null(this_); }; -inline void z_internal_null(z_owned_shm_client_storage_t* this_) { z_internal_shm_client_storage_null(this_); }; -inline void z_internal_null(z_owned_shm_mut_t* this_) { z_internal_shm_mut_null(this_); }; -inline void z_internal_null(z_owned_shm_t* this_) { z_internal_shm_null(this_); }; -inline void z_internal_null(z_owned_shm_provider_t* this_) { z_internal_shm_provider_null(this_); }; inline void z_internal_null(z_owned_slice_t* this_) { z_internal_slice_null(this_); }; -inline void z_internal_null(z_owned_source_info_t* this_) { z_internal_source_info_null(this_); }; inline void z_internal_null(z_owned_string_array_t* this_) { z_internal_string_array_null(this_); }; inline void z_internal_null(z_owned_string_t* this_) { z_internal_string_null(this_); }; inline void z_internal_null(z_owned_subscriber_t* this_) { z_internal_subscriber_null(this_); }; inline void z_internal_null(z_owned_task_t* this_) { z_internal_task_null(this_); }; inline void z_internal_null(zc_owned_closure_log_t* this_) { zc_internal_closure_log_null(this_); }; -inline void z_internal_null(zc_owned_closure_matching_status_t* this_) { zc_internal_closure_matching_status_null(this_); }; -inline void z_internal_null(zc_owned_matching_listener_t* this_) { zc_internal_matching_listener_null(this_); }; -inline void z_internal_null(zc_owned_shm_client_list_t* this_) { zc_internal_shm_client_list_null(this_); }; -inline void z_internal_null(ze_owned_publication_cache_t* this_) { ze_internal_publication_cache_null(this_); }; -inline void z_internal_null(ze_owned_querying_subscriber_t* this_) { ze_internal_querying_subscriber_null(this_); }; inline void z_internal_null(ze_owned_serializer_t* this_) { ze_internal_serializer_null(this_); }; -static inline void z_alloc_layout_take(z_owned_alloc_layout_t* this_, z_moved_alloc_layout_t* x) { *this_ = x->_this; z_internal_alloc_layout_null(&x->_this); } static inline void z_bytes_take(z_owned_bytes_t* this_, z_moved_bytes_t* x) { *this_ = x->_this; z_internal_bytes_null(&x->_this); } static inline void z_bytes_writer_take(z_owned_bytes_writer_t* this_, z_moved_bytes_writer_t* x) { *this_ = x->_this; z_internal_bytes_writer_null(&x->_this); } -static inline void z_chunk_alloc_result_take(z_owned_chunk_alloc_result_t* this_, z_moved_chunk_alloc_result_t* x) { *this_ = x->_this; z_internal_chunk_alloc_result_null(&x->_this); } static inline void z_closure_hello_take(z_owned_closure_hello_t* this_, z_moved_closure_hello_t* x) { *this_ = x->_this; z_internal_closure_hello_null(&x->_this); } static inline void z_closure_query_take(z_owned_closure_query_t* closure_, z_moved_closure_query_t* x) { *closure_ = x->_this; z_internal_closure_query_null(&x->_this); } static inline void z_closure_reply_take(z_owned_closure_reply_t* closure_, z_moved_closure_reply_t* x) { *closure_ = x->_this; z_internal_closure_reply_null(&x->_this); } @@ -789,8 +587,6 @@ static inline void z_fifo_handler_reply_take(z_owned_fifo_handler_reply_t* this_ static inline void z_fifo_handler_sample_take(z_owned_fifo_handler_sample_t* this_, z_moved_fifo_handler_sample_t* x) { *this_ = x->_this; z_internal_fifo_handler_sample_null(&x->_this); } static inline void z_hello_take(z_owned_hello_t* this_, z_moved_hello_t* x) { *this_ = x->_this; z_internal_hello_null(&x->_this); } static inline void z_keyexpr_take(z_owned_keyexpr_t* this_, z_moved_keyexpr_t* x) { *this_ = x->_this; z_internal_keyexpr_null(&x->_this); } -static inline void z_liveliness_token_take(z_owned_liveliness_token_t* this_, z_moved_liveliness_token_t* x) { *this_ = x->_this; z_internal_liveliness_token_null(&x->_this); } -static inline void z_memory_layout_take(z_owned_memory_layout_t* this_, z_moved_memory_layout_t* x) { *this_ = x->_this; z_internal_memory_layout_null(&x->_this); } static inline void z_mutex_take(z_owned_mutex_t* this_, z_moved_mutex_t* x) { *this_ = x->_this; z_internal_mutex_null(&x->_this); } static inline void z_publisher_take(z_owned_publisher_t* this_, z_moved_publisher_t* x) { *this_ = x->_this; z_internal_publisher_null(&x->_this); } static inline void z_query_take(z_owned_query_t* this_, z_moved_query_t* x) { *this_ = x->_this; z_internal_query_null(&x->_this); } @@ -802,39 +598,22 @@ static inline void z_ring_handler_reply_take(z_owned_ring_handler_reply_t* this_ static inline void z_ring_handler_sample_take(z_owned_ring_handler_sample_t* this_, z_moved_ring_handler_sample_t* x) { *this_ = x->_this; z_internal_ring_handler_sample_null(&x->_this); } static inline void z_sample_take(z_owned_sample_t* this_, z_moved_sample_t* x) { *this_ = x->_this; z_internal_sample_null(&x->_this); } static inline void z_session_take(z_owned_session_t* this_, z_moved_session_t* x) { *this_ = x->_this; z_internal_session_null(&x->_this); } -static inline void z_shm_client_take(z_owned_shm_client_t* this_, z_moved_shm_client_t* x) { *this_ = x->_this; z_internal_shm_client_null(&x->_this); } -static inline void z_shm_client_storage_take(z_owned_shm_client_storage_t* this_, z_moved_shm_client_storage_t* x) { *this_ = x->_this; z_internal_shm_client_storage_null(&x->_this); } -static inline void z_shm_take(z_owned_shm_t* this_, z_moved_shm_t* x) { *this_ = x->_this; z_internal_shm_null(&x->_this); } -static inline void z_shm_mut_take(z_owned_shm_mut_t* this_, z_moved_shm_mut_t* x) { *this_ = x->_this; z_internal_shm_mut_null(&x->_this); } -static inline void z_shm_provider_take(z_owned_shm_provider_t* this_, z_moved_shm_provider_t* x) { *this_ = x->_this; z_internal_shm_provider_null(&x->_this); } static inline void z_slice_take(z_owned_slice_t* this_, z_moved_slice_t* x) { *this_ = x->_this; z_internal_slice_null(&x->_this); } -static inline void z_source_info_take(z_owned_source_info_t* this_, z_moved_source_info_t* x) { *this_ = x->_this; z_internal_source_info_null(&x->_this); } static inline void z_string_array_take(z_owned_string_array_t* this_, z_moved_string_array_t* x) { *this_ = x->_this; z_internal_string_array_null(&x->_this); } static inline void z_string_take(z_owned_string_t* this_, z_moved_string_t* x) { *this_ = x->_this; z_internal_string_null(&x->_this); } static inline void z_subscriber_take(z_owned_subscriber_t* this_, z_moved_subscriber_t* x) { *this_ = x->_this; z_internal_subscriber_null(&x->_this); } static inline void z_task_take(z_owned_task_t* this_, z_moved_task_t* x) { *this_ = x->_this; z_internal_task_null(&x->_this); } static inline void zc_closure_log_take(zc_owned_closure_log_t* closure_, zc_moved_closure_log_t* x) { *closure_ = x->_this; zc_internal_closure_log_null(&x->_this); } -static inline void zc_closure_matching_status_take(zc_owned_closure_matching_status_t* closure_, zc_moved_closure_matching_status_t* x) { *closure_ = x->_this; zc_internal_closure_matching_status_null(&x->_this); } -static inline void zc_publisher_matching_listener_take(zc_owned_matching_listener_t* this_, zc_moved_matching_listener_t* x) { *this_ = x->_this; zc_internal_matching_listener_null(&x->_this); } -static inline void zc_shm_client_list_take(zc_owned_shm_client_list_t* this_, zc_moved_shm_client_list_t* x) { *this_ = x->_this; zc_internal_shm_client_list_null(&x->_this); } -static inline void ze_publication_cache_take(ze_owned_publication_cache_t* this_, ze_moved_publication_cache_t* x) { *this_ = x->_this; ze_internal_publication_cache_null(&x->_this); } -static inline void ze_querying_subscriber_take(ze_owned_querying_subscriber_t* this_, ze_moved_querying_subscriber_t* x) { *this_ = x->_this; ze_internal_querying_subscriber_null(&x->_this); } static inline void ze_serializer_take(ze_owned_serializer_t* this_, ze_moved_serializer_t* x) { *this_ = x->_this; ze_internal_serializer_null(&x->_this); } -inline void z_take(z_owned_alloc_layout_t* this_, z_moved_alloc_layout_t* x) { - z_alloc_layout_take(this_, x); -}; inline void z_take(z_owned_bytes_t* this_, z_moved_bytes_t* x) { z_bytes_take(this_, x); }; inline void z_take(z_owned_bytes_writer_t* this_, z_moved_bytes_writer_t* x) { z_bytes_writer_take(this_, x); }; -inline void z_take(z_owned_chunk_alloc_result_t* this_, z_moved_chunk_alloc_result_t* x) { - z_chunk_alloc_result_take(this_, x); -}; inline void z_take(z_owned_closure_hello_t* this_, z_moved_closure_hello_t* x) { z_closure_hello_take(this_, x); }; @@ -874,12 +653,6 @@ inline void z_take(z_owned_hello_t* this_, z_moved_hello_t* x) { inline void z_take(z_owned_keyexpr_t* this_, z_moved_keyexpr_t* x) { z_keyexpr_take(this_, x); }; -inline void z_take(z_owned_liveliness_token_t* this_, z_moved_liveliness_token_t* x) { - z_liveliness_token_take(this_, x); -}; -inline void z_take(z_owned_memory_layout_t* this_, z_moved_memory_layout_t* x) { - z_memory_layout_take(this_, x); -}; inline void z_take(z_owned_mutex_t* this_, z_moved_mutex_t* x) { z_mutex_take(this_, x); }; @@ -913,27 +686,9 @@ inline void z_take(z_owned_sample_t* this_, z_moved_sample_t* x) { inline void z_take(z_owned_session_t* this_, z_moved_session_t* x) { z_session_take(this_, x); }; -inline void z_take(z_owned_shm_client_t* this_, z_moved_shm_client_t* x) { - z_shm_client_take(this_, x); -}; -inline void z_take(z_owned_shm_client_storage_t* this_, z_moved_shm_client_storage_t* x) { - z_shm_client_storage_take(this_, x); -}; -inline void z_take(z_owned_shm_t* this_, z_moved_shm_t* x) { - z_shm_take(this_, x); -}; -inline void z_take(z_owned_shm_mut_t* this_, z_moved_shm_mut_t* x) { - z_shm_mut_take(this_, x); -}; -inline void z_take(z_owned_shm_provider_t* this_, z_moved_shm_provider_t* x) { - z_shm_provider_take(this_, x); -}; inline void z_take(z_owned_slice_t* this_, z_moved_slice_t* x) { z_slice_take(this_, x); }; -inline void z_take(z_owned_source_info_t* this_, z_moved_source_info_t* x) { - z_source_info_take(this_, x); -}; inline void z_take(z_owned_string_array_t* this_, z_moved_string_array_t* x) { z_string_array_take(this_, x); }; @@ -949,30 +704,13 @@ inline void z_take(z_owned_task_t* this_, z_moved_task_t* x) { inline void z_take(zc_owned_closure_log_t* closure_, zc_moved_closure_log_t* x) { zc_closure_log_take(closure_, x); }; -inline void z_take(zc_owned_closure_matching_status_t* closure_, zc_moved_closure_matching_status_t* x) { - zc_closure_matching_status_take(closure_, x); -}; -inline void z_take(zc_owned_matching_listener_t* this_, zc_moved_matching_listener_t* x) { - zc_publisher_matching_listener_take(this_, x); -}; -inline void z_take(zc_owned_shm_client_list_t* this_, zc_moved_shm_client_list_t* x) { - zc_shm_client_list_take(this_, x); -}; -inline void z_take(ze_owned_publication_cache_t* this_, ze_moved_publication_cache_t* x) { - ze_publication_cache_take(this_, x); -}; -inline void z_take(ze_owned_querying_subscriber_t* this_, ze_moved_querying_subscriber_t* x) { - ze_querying_subscriber_take(this_, x); -}; inline void z_take(ze_owned_serializer_t* this_, ze_moved_serializer_t* x) { ze_serializer_take(this_, x); }; -inline bool z_internal_check(const z_owned_alloc_layout_t& this_) { return z_internal_alloc_layout_check(&this_); }; inline bool z_internal_check(const z_owned_bytes_t& this_) { return z_internal_bytes_check(&this_); }; inline bool z_internal_check(const z_owned_bytes_writer_t& this_) { return z_internal_bytes_writer_check(&this_); }; -inline bool z_internal_check(const z_owned_chunk_alloc_result_t& this_) { return z_internal_chunk_alloc_result_check(&this_); }; inline bool z_internal_check(const z_owned_closure_hello_t& this_) { return z_internal_closure_hello_check(&this_); }; inline bool z_internal_check(const z_owned_closure_query_t& this_) { return z_internal_closure_query_check(&this_); }; inline bool z_internal_check(const z_owned_closure_reply_t& this_) { return z_internal_closure_reply_check(&this_); }; @@ -986,8 +724,6 @@ inline bool z_internal_check(const z_owned_fifo_handler_reply_t& this_) { return inline bool z_internal_check(const z_owned_fifo_handler_sample_t& this_) { return z_internal_fifo_handler_sample_check(&this_); }; inline bool z_internal_check(const z_owned_hello_t& this_) { return z_internal_hello_check(&this_); }; inline bool z_internal_check(const z_owned_keyexpr_t& this_) { return z_internal_keyexpr_check(&this_); }; -inline bool z_internal_check(const z_owned_liveliness_token_t& this_) { return z_internal_liveliness_token_check(&this_); }; -inline bool z_internal_check(const z_owned_memory_layout_t& this_) { return z_internal_memory_layout_check(&this_); }; inline bool z_internal_check(const z_owned_mutex_t& this_) { return z_internal_mutex_check(&this_); }; inline bool z_internal_check(const z_owned_publisher_t& this_) { return z_internal_publisher_check(&this_); }; inline bool z_internal_check(const z_owned_query_t& query) { return z_internal_query_check(&query); }; @@ -999,23 +735,12 @@ inline bool z_internal_check(const z_owned_ring_handler_reply_t& this_) { return inline bool z_internal_check(const z_owned_ring_handler_sample_t& this_) { return z_internal_ring_handler_sample_check(&this_); }; inline bool z_internal_check(const z_owned_sample_t& this_) { return z_internal_sample_check(&this_); }; inline bool z_internal_check(const z_owned_session_t& this_) { return z_internal_session_check(&this_); }; -inline bool z_internal_check(const z_owned_shm_t& this_) { return z_internal_shm_check(&this_); }; -inline bool z_internal_check(const z_owned_shm_client_t& this_) { return z_internal_shm_client_check(&this_); }; -inline bool z_internal_check(const z_owned_shm_client_storage_t& this_) { return z_internal_shm_client_storage_check(&this_); }; -inline bool z_internal_check(const z_owned_shm_mut_t& this_) { return z_internal_shm_mut_check(&this_); }; -inline bool z_internal_check(const z_owned_shm_provider_t& this_) { return z_internal_shm_provider_check(&this_); }; inline bool z_internal_check(const z_owned_slice_t& this_) { return z_internal_slice_check(&this_); }; -inline bool z_internal_check(const z_owned_source_info_t& this_) { return z_internal_source_info_check(&this_); }; inline bool z_internal_check(const z_owned_string_array_t& this_) { return z_internal_string_array_check(&this_); }; inline bool z_internal_check(const z_owned_string_t& this_) { return z_internal_string_check(&this_); }; inline bool z_internal_check(const z_owned_subscriber_t& this_) { return z_internal_subscriber_check(&this_); }; inline bool z_internal_check(const z_owned_task_t& this_) { return z_internal_task_check(&this_); }; inline bool z_internal_check(const zc_owned_closure_log_t& this_) { return zc_internal_closure_log_check(&this_); }; -inline bool z_internal_check(const zc_owned_closure_matching_status_t& this_) { return zc_internal_closure_matching_status_check(&this_); }; -inline bool z_internal_check(const zc_owned_matching_listener_t& this_) { return zc_internal_matching_listener_check(&this_); }; -inline bool z_internal_check(const zc_owned_shm_client_list_t& this_) { return zc_internal_shm_client_list_check(&this_); }; -inline bool z_internal_check(const ze_owned_publication_cache_t& this_) { return ze_internal_publication_cache_check(&this_); }; -inline bool z_internal_check(const ze_owned_querying_subscriber_t& this_) { return ze_internal_querying_subscriber_check(&this_); }; inline bool z_internal_check(const ze_owned_serializer_t& this_) { return ze_internal_serializer_check(&this_); }; @@ -1034,9 +759,6 @@ inline void z_call(const z_loaned_closure_sample_t* closure, z_loaned_sample_t* inline void z_call(const z_loaned_closure_zid_t* closure, const z_id_t* z_id) { z_closure_zid_call(closure, z_id); }; -inline void z_call(const zc_loaned_closure_matching_status_t* closure, const zc_matching_status_t* mathing_status) { - zc_closure_matching_status_call(closure, mathing_status); -}; extern "C" using z_closure_drop_callback_t = void(void* context); extern "C" using z_closure_hello_callback_t = void(z_loaned_hello_t *hello, void *context); @@ -1045,7 +767,6 @@ extern "C" using z_closure_reply_callback_t = void(z_loaned_reply_t *reply, void extern "C" using z_closure_sample_callback_t = void(z_loaned_sample_t *sample, void *context); extern "C" using z_closure_zid_callback_t = void(const z_id_t *z_id, void *context); extern "C" using zc_closure_log_callback_t = void(zc_log_severity_t severity, const z_loaned_string_t *msg, void *context); -extern "C" using zc_closure_matching_status_callback_t = void(const zc_matching_status_t *matching_status, void *context); inline void z_closure(z_owned_closure_hello_t* this_, z_closure_hello_callback_t* call, z_closure_drop_callback_t* drop, void* context) { @@ -1071,10 +792,6 @@ inline void z_closure(zc_owned_closure_log_t* this_, zc_closure_log_callback_t* z_closure_drop_callback_t* drop, void* context) { zc_closure_log(this_, call, drop, context); }; -inline void z_closure(zc_owned_closure_matching_status_t* this_, zc_closure_matching_status_callback_t* call, - z_closure_drop_callback_t* drop, void* context) { - zc_closure_matching_status(this_, call, drop, context); -}; inline z_result_t z_try_recv(const z_loaned_fifo_handler_query_t* this_, z_owned_query_t* query) { @@ -1144,12 +861,6 @@ inline void z_clone(z_owned_reply_err_t* dst, z_loaned_reply_err_t* this_) { inline void z_clone(z_owned_sample_t* dst, z_loaned_sample_t* this_) { z_sample_clone(dst, this_); }; -inline void z_clone(z_owned_shm_client_storage_t* this_, z_loaned_shm_client_storage_t* from) { - z_shm_client_storage_clone(this_, from); -}; -inline void z_clone(z_owned_shm_t* out, z_loaned_shm_t* this_) { - z_shm_clone(out, this_); -}; inline void z_clone(z_owned_slice_t* dst, z_loaned_slice_t* this_) { z_slice_clone(dst, this_); }; @@ -1162,8 +873,6 @@ inline void z_clone(z_owned_string_t* dst, z_loaned_string_t* this_) { template struct z_loaned_to_owned_type_t {}; template struct z_owned_to_loaned_type_t {}; -template<> struct z_loaned_to_owned_type_t { typedef z_owned_alloc_layout_t type; }; -template<> struct z_owned_to_loaned_type_t { typedef z_loaned_alloc_layout_t type; }; template<> struct z_loaned_to_owned_type_t { typedef z_owned_bytes_t type; }; template<> struct z_owned_to_loaned_type_t { typedef z_loaned_bytes_t type; }; template<> struct z_loaned_to_owned_type_t { typedef z_owned_bytes_writer_t type; }; @@ -1194,10 +903,6 @@ template<> struct z_loaned_to_owned_type_t { typedef z_owned_h template<> struct z_owned_to_loaned_type_t { typedef z_loaned_hello_t type; }; template<> struct z_loaned_to_owned_type_t { typedef z_owned_keyexpr_t type; }; template<> struct z_owned_to_loaned_type_t { typedef z_loaned_keyexpr_t type; }; -template<> struct z_loaned_to_owned_type_t { typedef z_owned_liveliness_token_t type; }; -template<> struct z_owned_to_loaned_type_t { typedef z_loaned_liveliness_token_t type; }; -template<> struct z_loaned_to_owned_type_t { typedef z_owned_memory_layout_t type; }; -template<> struct z_owned_to_loaned_type_t { typedef z_loaned_memory_layout_t type; }; template<> struct z_loaned_to_owned_type_t { typedef z_owned_publisher_t type; }; template<> struct z_owned_to_loaned_type_t { typedef z_loaned_publisher_t type; }; template<> struct z_loaned_to_owned_type_t { typedef z_owned_query_t type; }; @@ -1218,18 +923,8 @@ template<> struct z_loaned_to_owned_type_t { typedef z_owned_ template<> struct z_owned_to_loaned_type_t { typedef z_loaned_sample_t type; }; template<> struct z_loaned_to_owned_type_t { typedef z_owned_session_t type; }; template<> struct z_owned_to_loaned_type_t { typedef z_loaned_session_t type; }; -template<> struct z_loaned_to_owned_type_t { typedef z_owned_shm_client_storage_t type; }; -template<> struct z_owned_to_loaned_type_t { typedef z_loaned_shm_client_storage_t type; }; -template<> struct z_loaned_to_owned_type_t { typedef z_owned_shm_t type; }; -template<> struct z_owned_to_loaned_type_t { typedef z_loaned_shm_t type; }; -template<> struct z_loaned_to_owned_type_t { typedef z_owned_shm_mut_t type; }; -template<> struct z_owned_to_loaned_type_t { typedef z_loaned_shm_mut_t type; }; -template<> struct z_loaned_to_owned_type_t { typedef z_owned_shm_provider_t type; }; -template<> struct z_owned_to_loaned_type_t { typedef z_loaned_shm_provider_t type; }; template<> struct z_loaned_to_owned_type_t { typedef z_owned_slice_t type; }; template<> struct z_owned_to_loaned_type_t { typedef z_loaned_slice_t type; }; -template<> struct z_loaned_to_owned_type_t { typedef z_owned_source_info_t type; }; -template<> struct z_owned_to_loaned_type_t { typedef z_loaned_source_info_t type; }; template<> struct z_loaned_to_owned_type_t { typedef z_owned_string_array_t type; }; template<> struct z_owned_to_loaned_type_t { typedef z_loaned_string_array_t type; }; template<> struct z_loaned_to_owned_type_t { typedef z_owned_string_t type; }; @@ -1238,14 +933,6 @@ template<> struct z_loaned_to_owned_type_t { typedef z_ow template<> struct z_owned_to_loaned_type_t { typedef z_loaned_subscriber_t type; }; template<> struct z_loaned_to_owned_type_t { typedef zc_owned_closure_log_t type; }; template<> struct z_owned_to_loaned_type_t { typedef zc_loaned_closure_log_t type; }; -template<> struct z_loaned_to_owned_type_t { typedef zc_owned_closure_matching_status_t type; }; -template<> struct z_owned_to_loaned_type_t { typedef zc_loaned_closure_matching_status_t type; }; -template<> struct z_loaned_to_owned_type_t { typedef zc_owned_shm_client_list_t type; }; -template<> struct z_owned_to_loaned_type_t { typedef zc_loaned_shm_client_list_t type; }; -template<> struct z_loaned_to_owned_type_t { typedef ze_owned_publication_cache_t type; }; -template<> struct z_owned_to_loaned_type_t { typedef ze_loaned_publication_cache_t type; }; -template<> struct z_loaned_to_owned_type_t { typedef ze_owned_querying_subscriber_t type; }; -template<> struct z_owned_to_loaned_type_t { typedef ze_loaned_querying_subscriber_t type; }; template<> struct z_loaned_to_owned_type_t { typedef ze_owned_serializer_t type; }; template<> struct z_owned_to_loaned_type_t { typedef ze_loaned_serializer_t type; }; template<> struct z_loaned_to_owned_type_t { typedef z_owned_mutex_t type; }; From 942bb4a5b69f28f9d99c3cd2aa45f9d115fdac45 Mon Sep 17 00:00:00 2001 From: Michael Ilyin Date: Tue, 3 Dec 2024 13:46:49 +0100 Subject: [PATCH 5/6] doc updated --- include/zenoh_commons.h | 2 +- src/liveliness.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/zenoh_commons.h b/include/zenoh_commons.h index 8a8ac366e..736ed6e52 100644 --- a/include/zenoh_commons.h +++ b/include/zenoh_commons.h @@ -785,7 +785,7 @@ typedef struct z_liveliness_token_options_t { #if defined(Z_FEATURE_UNSTABLE_API) typedef struct z_liveliness_get_options_t { /** - * Set query timeout in milliseconds. + * The timeout for the liveliness query in milliseconds. 0 means default query timeout from zenoh configuration. */ uint32_t timeout_ms; } z_liveliness_get_options_t; diff --git a/src/liveliness.rs b/src/liveliness.rs index 2c8e2b31f..b62673c0c 100644 --- a/src/liveliness.rs +++ b/src/liveliness.rs @@ -238,7 +238,7 @@ pub extern "C" fn zc_liveliness_declare_background_subscriber( /// @brief The options for `z_liveliness_get()` #[repr(C)] pub struct z_liveliness_get_options_t { - /// Set query timeout in milliseconds. + /// The timeout for the liveliness query in milliseconds. 0 means default query timeout from zenoh configuration. timeout_ms: u32, } From 8c0f5ee01fb57cda93f5a113419ba5a01d69cbc5 Mon Sep 17 00:00:00 2001 From: Michael Ilyin Date: Tue, 3 Dec 2024 13:49:02 +0100 Subject: [PATCH 6/6] doc updated --- include/zenoh_commons.h | 2 +- src/liveliness.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/zenoh_commons.h b/include/zenoh_commons.h index 736ed6e52..f221a77d0 100644 --- a/include/zenoh_commons.h +++ b/include/zenoh_commons.h @@ -764,7 +764,7 @@ typedef struct z_moved_keyexpr_t { #if defined(Z_FEATURE_UNSTABLE_API) typedef struct z_liveliness_subscriber_options_t { /** - * Receive liveliness tokens that were declared before this liveliness subscriber. + * If true, subscriber will receive the state change notifications for liveliness tokens that were declared before its declaration. */ bool history; } z_liveliness_subscriber_options_t; diff --git a/src/liveliness.rs b/src/liveliness.rs index b62673c0c..de6da556a 100644 --- a/src/liveliness.rs +++ b/src/liveliness.rs @@ -138,7 +138,7 @@ pub extern "C" fn z_liveliness_undeclare_token( /// @brief The options for `z_liveliness_declare_subscriber()` #[repr(C)] pub struct z_liveliness_subscriber_options_t { - /// Receive liveliness tokens that were declared before this liveliness subscriber. + /// If true, subscriber will receive the state change notifications for liveliness tokens that were declared before its declaration. history: bool, }