From: Philippe Proulx Date: Sat, 25 Nov 2023 16:13:57 +0000 (-0500) Subject: include/babeltrace2: add `noexcept` specifier for C++ ≥ 11 X-Git-Url: https://git.efficios.com/?a=commitdiff_plain;h=4c81a2b7cb0899f52a228249beb91f2814bbe601;p=babeltrace.git include/babeltrace2: add `noexcept` specifier for C++ ≥ 11 This patch adds the `noexcept` specifier to all the public functions when building with C++11 and above. This is similar to what glibc does (from `/usr/include/sys/cdefs.h`): # if __cplusplus >= 201103L # define __THROW noexcept (true) # else # define __THROW throw () # endif and then, for example (`/usr/include/string.h`): /* Return the length of S. */ extern size_t strlen (const char *__s) __THROW __attribute_pure__ __nonnull ((1)); Indeed, none of our functions throw, ever, including user callbacks, because the library always expects them to return some value (doesn't catch, in other words). This brings an improvement to a `noexcept` function calling a libbabeltrace2 function. For example, consider this simple case: uint64_t get_cs_value(const bt_clock_snapshot * const opt_cs) noexcept { return bt_clock_snapshot_get_value(opt_cs); } When bt_clock_snapshot_get_value() isn't `noexcept`, we get (`-O2`): get_cs_value(bt_clock_snapshot const*): sub rsp, 8 call bt_clock_snapshot_get_value add rsp, 8 ret With `noexcept`: get_cs_value(bt_clock_snapshot const*): jmp bt_clock_snapshot_get_value In other words, without this patch, there's some stack adjustment to prepare for a possible exception when you're already in `noexcept` mode. Signed-off-by: Philippe Proulx Change-Id: I0712eab48de93344159b7b7344f28b940ed81712 Reviewed-on: https://review.lttng.org/c/babeltrace/+/11442 Reviewed-by: Simon Marchi CI-Build: Simon Marchi Tested-by: jenkins --- diff --git a/include/babeltrace2/babeltrace.h b/include/babeltrace2/babeltrace.h index 82c402ad..82f62514 100644 --- a/include/babeltrace2/babeltrace.h +++ b/include/babeltrace2/babeltrace.h @@ -45,6 +45,13 @@ #define __BT_ATTR_FORMAT_PRINTF(_string_index, _first_to_check) \ __attribute__((format(__BT_PRINTF_FORMAT, _string_index, _first_to_check))) +/* Internal: `noexcept` specifier if C++ ≥ 11 */ +#if defined(__cplusplus) && (__cplusplus >= 201103L || (defined(_MSC_VER) && _MSC_VER >= 1900)) +# define __BT_NOEXCEPT noexcept +#else +# define __BT_NOEXCEPT +#endif + #include #include #include @@ -104,5 +111,6 @@ #undef __BT_LOGGING_LEVEL_ERROR #undef __BT_LOGGING_LEVEL_FATAL #undef __BT_LOGGING_LEVEL_NONE +#undef __BT_NOEXCEPT #endif /* BABELTRACE2_BABELTRACE_H */ diff --git a/include/babeltrace2/error-reporting.h b/include/babeltrace2/error-reporting.h index 7c4b1541..29e53e16 100644 --- a/include/babeltrace2/error-reporting.h +++ b/include/babeltrace2/error-reporting.h @@ -433,7 +433,7 @@ Once you are done with the returned error, do one of: Moves an error's ownership to the library. */ extern -const bt_error *bt_current_thread_take_error(void); +const bt_error *bt_current_thread_take_error(void) __BT_NOEXCEPT; /*! @brief @@ -466,7 +466,7 @@ corresponds to catching an exception and discarding it. Calls this function and assigns \c NULL to the expression. */ extern -void bt_current_thread_move_error(const bt_error *error); +void bt_current_thread_move_error(const bt_error *error) __BT_NOEXCEPT; /*! @brief @@ -513,7 +513,7 @@ bt_error_release(bt_current_thread_take_error()); library to the caller. */ extern -void bt_current_thread_clear_error(void); +void bt_current_thread_clear_error(void) __BT_NOEXCEPT; /*! @} */ @@ -618,7 +618,8 @@ extern __BT_ATTR_FORMAT_PRINTF(4, 5) bt_current_thread_error_append_cause_status bt_current_thread_error_append_cause_from_component( bt_self_component *self_component, const char *file_name, - uint64_t line_number, const char *message_format, ...); + uint64_t line_number, + const char *message_format, ...) __BT_NOEXCEPT; /*! @brief @@ -718,7 +719,7 @@ bt_current_thread_error_append_cause_status bt_current_thread_error_append_cause_from_message_iterator( bt_self_message_iterator *self_message_iterator, const char *file_name, uint64_t line_number, - const char *message_format, ...); + const char *message_format, ...) __BT_NOEXCEPT; /*! @brief @@ -810,7 +811,7 @@ bt_current_thread_error_append_cause_status bt_current_thread_error_append_cause_from_component_class( bt_self_component_class *self_component_class, const char *file_name, uint64_t line_number, - const char *message_format, ...); + const char *message_format, ...) __BT_NOEXCEPT; /*! @brief @@ -873,7 +874,8 @@ extern __BT_ATTR_FORMAT_PRINTF(4, 5) bt_current_thread_error_append_cause_status bt_current_thread_error_append_cause_from_unknown( const char *module_name, const char *file_name, - uint64_t line_number, const char *message_format, ...); + uint64_t line_number, + const char *message_format, ...) __BT_NOEXCEPT; /*! @brief @@ -915,7 +917,7 @@ with \c __FILE__ and \c __LINE__ as its @bt_pre_not_null{error} */ extern -uint64_t bt_error_get_cause_count(const bt_error *error); +uint64_t bt_error_get_cause_count(const bt_error *error) __BT_NOEXCEPT; /*! @brief @@ -942,7 +944,7 @@ uint64_t bt_error_get_cause_count(const bt_error *error); */ extern const bt_error_cause *bt_error_borrow_cause_by_index( - const bt_error *error, uint64_t index); + const bt_error *error, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -973,7 +975,7 @@ corresponds to catching an exception and rethrowing it. Moves an error's ownership to the library. */ extern -void bt_error_release(const bt_error *error); +void bt_error_release(const bt_error *error) __BT_NOEXCEPT; /*! @} */ @@ -1027,7 +1029,7 @@ typedef enum bt_error_cause_actor_type { */ extern bt_error_cause_actor_type bt_error_cause_get_actor_type( - const bt_error_cause *error_cause); + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @brief @@ -1047,7 +1049,8 @@ bt_error_cause_actor_type bt_error_cause_get_actor_type( @bt_pre_not_null{error_cause} */ extern -const char *bt_error_cause_get_message(const bt_error_cause *error_cause); +const char *bt_error_cause_get_message( + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @brief @@ -1067,7 +1070,8 @@ const char *bt_error_cause_get_message(const bt_error_cause *error_cause); @bt_pre_not_null{error_cause} */ extern -const char *bt_error_cause_get_module_name(const bt_error_cause *error_cause); +const char *bt_error_cause_get_module_name( + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @brief @@ -1089,7 +1093,8 @@ const char *bt_error_cause_get_module_name(const bt_error_cause *error_cause); @bt_pre_not_null{error_cause} */ extern -const char *bt_error_cause_get_file_name(const bt_error_cause *error_cause); +const char *bt_error_cause_get_file_name( + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @brief @@ -1106,7 +1111,8 @@ const char *bt_error_cause_get_file_name(const bt_error_cause *error_cause); @bt_pre_not_null{error_cause} */ extern -uint64_t bt_error_cause_get_line_number(const bt_error_cause *error_cause); +uint64_t bt_error_cause_get_line_number( + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @} */ @@ -1139,7 +1145,7 @@ uint64_t bt_error_cause_get_line_number(const bt_error_cause *error_cause); */ extern const char *bt_error_cause_component_actor_get_component_name( - const bt_error_cause *error_cause); + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @brief @@ -1160,7 +1166,7 @@ const char *bt_error_cause_component_actor_get_component_name( */ extern bt_component_class_type bt_error_cause_component_actor_get_component_class_type( - const bt_error_cause *error_cause); + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @brief @@ -1186,7 +1192,7 @@ bt_component_class_type bt_error_cause_component_actor_get_component_class_type( */ extern const char *bt_error_cause_component_actor_get_component_class_name( - const bt_error_cause *error_cause); + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @brief @@ -1217,7 +1223,7 @@ component class. */ extern const char *bt_error_cause_component_actor_get_plugin_name( - const bt_error_cause *error_cause); + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @} */ @@ -1251,7 +1257,7 @@ const char *bt_error_cause_component_actor_get_plugin_name( */ extern const char *bt_error_cause_message_iterator_actor_get_component_output_port_name( - const bt_error_cause *error_cause); + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @brief @@ -1277,7 +1283,7 @@ const char *bt_error_cause_message_iterator_actor_get_component_output_port_name */ extern const char *bt_error_cause_message_iterator_actor_get_component_name( - const bt_error_cause *error_cause); + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @brief @@ -1299,7 +1305,7 @@ const char *bt_error_cause_message_iterator_actor_get_component_name( extern bt_component_class_type bt_error_cause_message_iterator_actor_get_component_class_type( - const bt_error_cause *error_cause); + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @brief @@ -1325,7 +1331,7 @@ bt_error_cause_message_iterator_actor_get_component_class_type( */ extern const char *bt_error_cause_message_iterator_actor_get_component_class_name( - const bt_error_cause *error_cause); + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @brief @@ -1357,7 +1363,7 @@ component class. */ extern const char *bt_error_cause_message_iterator_actor_get_plugin_name( - const bt_error_cause *error_cause); + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @} */ @@ -1386,7 +1392,7 @@ const char *bt_error_cause_message_iterator_actor_get_plugin_name( extern bt_component_class_type bt_error_cause_component_class_actor_get_component_class_type( - const bt_error_cause *error_cause); + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @brief @@ -1412,7 +1418,7 @@ bt_error_cause_component_class_actor_get_component_class_type( */ extern const char *bt_error_cause_component_class_actor_get_component_class_name( - const bt_error_cause *error_cause); + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @brief @@ -1443,7 +1449,7 @@ component class. */ extern const char *bt_error_cause_component_class_actor_get_plugin_name( - const bt_error_cause *error_cause); + const bt_error_cause *error_cause) __BT_NOEXCEPT; /*! @} */ diff --git a/include/babeltrace2/graph/component-class-dev.h b/include/babeltrace2/graph/component-class-dev.h index eaf288f9..d79dc6c4 100644 --- a/include/babeltrace2/graph/component-class-dev.h +++ b/include/babeltrace2/graph/component-class-dev.h @@ -1476,7 +1476,8 @@ property values: extern bt_component_class_source *bt_component_class_source_create( const char *name, - bt_message_iterator_class *message_iterator_class); + bt_message_iterator_class *message_iterator_class) + __BT_NOEXCEPT; /*! @brief @@ -1520,7 +1521,8 @@ property values: extern bt_component_class_filter *bt_component_class_filter_create( const char *name, - bt_message_iterator_class *message_iterator_class); + bt_message_iterator_class *message_iterator_class) + __BT_NOEXCEPT; /*! @brief @@ -1560,7 +1562,8 @@ property values: extern bt_component_class_sink *bt_component_class_sink_create( const char *name, - bt_component_class_sink_consume_method consume_method); + bt_component_class_sink_consume_method consume_method) + __BT_NOEXCEPT; /*! @} */ @@ -1614,7 +1617,7 @@ See the \ref api-comp-cls-prop-descr "description" property. */ extern bt_component_class_set_description_status bt_component_class_set_description(bt_component_class *component_class, - const char *description); + const char *description) __BT_NOEXCEPT; /*! @brief @@ -1661,7 +1664,7 @@ See the \ref api-comp-cls-prop-help "help text" property. */ extern bt_component_class_set_help_status bt_component_class_set_help( bt_component_class *component_class, - const char *help_text); + const char *help_text) __BT_NOEXCEPT; /*! @} */ @@ -1706,7 +1709,7 @@ See the \ref api-comp-cls-dev-meth-fini "finalize" method. extern bt_component_class_set_method_status bt_component_class_source_set_finalize_method( bt_component_class_source *component_class, - bt_component_class_source_finalize_method method); + bt_component_class_source_finalize_method method) __BT_NOEXCEPT; /*! @brief @@ -1731,7 +1734,7 @@ See the \ref api-comp-cls-dev-meth-fini "finalize" method. extern bt_component_class_set_method_status bt_component_class_filter_set_finalize_method( bt_component_class_filter *component_class, - bt_component_class_filter_finalize_method method); + bt_component_class_filter_finalize_method method) __BT_NOEXCEPT; /*! @brief @@ -1757,7 +1760,7 @@ extern bt_component_class_set_method_status bt_component_class_sink_set_finalize_method( bt_component_class_sink *component_class, - bt_component_class_sink_finalize_method method); + bt_component_class_sink_finalize_method method) __BT_NOEXCEPT; /*! @brief @@ -1783,7 +1786,8 @@ method. extern bt_component_class_set_method_status bt_component_class_source_set_get_supported_mip_versions_method( bt_component_class_source *component_class, - bt_component_class_source_get_supported_mip_versions_method method); + bt_component_class_source_get_supported_mip_versions_method method) + __BT_NOEXCEPT; /*! @brief @@ -1809,7 +1813,8 @@ method. extern bt_component_class_set_method_status bt_component_class_filter_set_get_supported_mip_versions_method( bt_component_class_filter *component_class, - bt_component_class_filter_get_supported_mip_versions_method method); + bt_component_class_filter_get_supported_mip_versions_method method) + __BT_NOEXCEPT; /*! @brief @@ -1835,7 +1840,8 @@ method. extern bt_component_class_set_method_status bt_component_class_sink_set_get_supported_mip_versions_method( bt_component_class_sink *component_class, - bt_component_class_sink_get_supported_mip_versions_method method); + bt_component_class_sink_get_supported_mip_versions_method method) + __BT_NOEXCEPT; /*! @brief @@ -1863,7 +1869,8 @@ extern bt_component_class_set_method_status bt_component_class_sink_set_graph_is_configured_method( bt_component_class_sink *component_class, - bt_component_class_sink_graph_is_configured_method method); + bt_component_class_sink_graph_is_configured_method method) + __BT_NOEXCEPT; /*! @brief @@ -1888,7 +1895,8 @@ See the \ref api-comp-cls-dev-meth-init "initialize" method. extern bt_component_class_set_method_status bt_component_class_source_set_initialize_method( bt_component_class_source *component_class, - bt_component_class_source_initialize_method method); + bt_component_class_source_initialize_method method) + __BT_NOEXCEPT; /*! @brief @@ -1913,7 +1921,8 @@ See the \ref api-comp-cls-dev-meth-init "initialize" method. extern bt_component_class_set_method_status bt_component_class_filter_set_initialize_method( bt_component_class_filter *component_class, - bt_component_class_filter_initialize_method method); + bt_component_class_filter_initialize_method method) + __BT_NOEXCEPT; /*! @brief @@ -1939,7 +1948,7 @@ extern bt_component_class_set_method_status bt_component_class_sink_set_initialize_method( bt_component_class_sink *component_class, - bt_component_class_sink_initialize_method method); + bt_component_class_sink_initialize_method method) __BT_NOEXCEPT; /*! @brief @@ -1966,7 +1975,8 @@ method. extern bt_component_class_set_method_status bt_component_class_source_set_output_port_connected_method( bt_component_class_source *component_class, - bt_component_class_source_output_port_connected_method method); + bt_component_class_source_output_port_connected_method method) + __BT_NOEXCEPT; /*! @brief @@ -1993,7 +2003,8 @@ method. extern bt_component_class_set_method_status bt_component_class_filter_set_input_port_connected_method( bt_component_class_filter *component_class, - bt_component_class_filter_input_port_connected_method method); + bt_component_class_filter_input_port_connected_method method) + __BT_NOEXCEPT; /*! @brief @@ -2020,7 +2031,8 @@ method. extern bt_component_class_set_method_status bt_component_class_filter_set_output_port_connected_method( bt_component_class_filter *component_class, - bt_component_class_filter_output_port_connected_method method); + bt_component_class_filter_output_port_connected_method method) + __BT_NOEXCEPT; /*! @brief @@ -2048,7 +2060,8 @@ extern bt_component_class_set_method_status bt_component_class_sink_set_input_port_connected_method( bt_component_class_sink *component_class, - bt_component_class_sink_input_port_connected_method method); + bt_component_class_sink_input_port_connected_method method) + __BT_NOEXCEPT; /*! @brief @@ -2073,7 +2086,7 @@ See the \ref api-comp-cls-dev-meth-query "query" method. extern bt_component_class_set_method_status bt_component_class_source_set_query_method( bt_component_class_source *component_class, - bt_component_class_source_query_method method); + bt_component_class_source_query_method method) __BT_NOEXCEPT; /*! @brief @@ -2098,7 +2111,7 @@ See the \ref api-comp-cls-dev-meth-query "query" method. extern bt_component_class_set_method_status bt_component_class_filter_set_query_method( bt_component_class_filter *component_class, - bt_component_class_filter_query_method method); + bt_component_class_filter_query_method method) __BT_NOEXCEPT; /*! @brief @@ -2124,7 +2137,7 @@ extern bt_component_class_set_method_status bt_component_class_sink_set_query_method( bt_component_class_sink *component_class, - bt_component_class_sink_query_method method); + bt_component_class_sink_query_method method) __BT_NOEXCEPT; /*! @} */ @@ -2150,7 +2163,7 @@ bt_component_class_sink_set_query_method( */ static inline bt_component_class *bt_component_class_source_as_component_class( - bt_component_class_source *component_class) + bt_component_class_source *component_class) __BT_NOEXCEPT { return __BT_UPCAST(bt_component_class, component_class); } @@ -2172,7 +2185,7 @@ bt_component_class *bt_component_class_source_as_component_class( */ static inline bt_component_class *bt_component_class_filter_as_component_class( - bt_component_class_filter *component_class) + bt_component_class_filter *component_class) __BT_NOEXCEPT { return __BT_UPCAST(bt_component_class, component_class); } @@ -2194,7 +2207,7 @@ bt_component_class *bt_component_class_filter_as_component_class( */ static inline bt_component_class *bt_component_class_sink_as_component_class( - bt_component_class_sink *component_class) + bt_component_class_sink *component_class) __BT_NOEXCEPT { return __BT_UPCAST(bt_component_class, component_class); } diff --git a/include/babeltrace2/graph/component-class.h b/include/babeltrace2/graph/component-class.h index e08334db..05fd7f3c 100644 --- a/include/babeltrace2/graph/component-class.h +++ b/include/babeltrace2/graph/component-class.h @@ -238,7 +238,7 @@ typedef enum bt_component_class_type { Returns whether or not a component class is a \bt_sink_comp_cls. */ extern bt_component_class_type bt_component_class_get_type( - const bt_component_class *component_class); + const bt_component_class *component_class) __BT_NOEXCEPT; /*! @brief @@ -258,7 +258,7 @@ extern bt_component_class_type bt_component_class_get_type( */ static inline bt_bool bt_component_class_is_source( - const bt_component_class *component_class) + const bt_component_class *component_class) __BT_NOEXCEPT { return bt_component_class_get_type(component_class) == BT_COMPONENT_CLASS_TYPE_SOURCE; @@ -282,7 +282,7 @@ bt_bool bt_component_class_is_source( */ static inline bt_bool bt_component_class_is_filter( - const bt_component_class *component_class) + const bt_component_class *component_class) __BT_NOEXCEPT { return bt_component_class_get_type(component_class) == BT_COMPONENT_CLASS_TYPE_FILTER; @@ -306,7 +306,7 @@ bt_bool bt_component_class_is_filter( */ static inline bt_bool bt_component_class_is_sink( - const bt_component_class *component_class) + const bt_component_class *component_class) __BT_NOEXCEPT { return bt_component_class_get_type(component_class) == BT_COMPONENT_CLASS_TYPE_SINK; @@ -339,7 +339,7 @@ See the \ref api-comp-cls-prop-name "name" property. @bt_pre_not_null{component_class} */ extern const char *bt_component_class_get_name( - const bt_component_class *component_class); + const bt_component_class *component_class) __BT_NOEXCEPT; /*! @brief @@ -362,7 +362,7 @@ See the \ref api-comp-cls-prop-descr "description" property. @bt_pre_not_null{component_class} */ extern const char *bt_component_class_get_description( - const bt_component_class *component_class); + const bt_component_class *component_class) __BT_NOEXCEPT; /*! @brief @@ -384,7 +384,7 @@ See the \ref api-comp-cls-prop-help "help text" property. @bt_pre_not_null{component_class} */ extern const char *bt_component_class_get_help( - const bt_component_class *component_class); + const bt_component_class *component_class) __BT_NOEXCEPT; /*! @} */ @@ -409,7 +409,7 @@ extern const char *bt_component_class_get_help( Decrements the reference count of a component class. */ extern void bt_component_class_get_ref( - const bt_component_class *component_class); + const bt_component_class *component_class) __BT_NOEXCEPT; /*! @brief @@ -427,7 +427,7 @@ extern void bt_component_class_get_ref( Increments the reference count of a component class. */ extern void bt_component_class_put_ref( - const bt_component_class *component_class); + const bt_component_class *component_class) __BT_NOEXCEPT; /*! @brief @@ -509,7 +509,7 @@ expression static inline const bt_component_class * bt_component_class_source_as_component_class_const( - const bt_component_class_source *component_class) + const bt_component_class_source *component_class) __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_component_class, component_class); } @@ -537,7 +537,7 @@ bt_component_class_source_as_component_class_const( Decrements the reference count of a source component class. */ extern void bt_component_class_source_get_ref( - const bt_component_class_source *component_class); + const bt_component_class_source *component_class) __BT_NOEXCEPT; /*! @brief @@ -555,7 +555,7 @@ extern void bt_component_class_source_get_ref( Increments the reference count of a source component class. */ extern void bt_component_class_source_put_ref( - const bt_component_class_source *component_class); + const bt_component_class_source *component_class) __BT_NOEXCEPT; /*! @brief @@ -636,7 +636,7 @@ existing \bt_p{_dst} reference. static inline const bt_component_class * bt_component_class_filter_as_component_class_const( - const bt_component_class_filter *component_class) + const bt_component_class_filter *component_class) __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_component_class, component_class); } @@ -664,7 +664,7 @@ bt_component_class_filter_as_component_class_const( Decrements the reference count of a filter component class. */ extern void bt_component_class_filter_get_ref( - const bt_component_class_filter *component_class); + const bt_component_class_filter *component_class) __BT_NOEXCEPT; /*! @brief @@ -682,7 +682,7 @@ extern void bt_component_class_filter_get_ref( Increments the reference count of a filter component class. */ extern void bt_component_class_filter_put_ref( - const bt_component_class_filter *component_class); + const bt_component_class_filter *component_class) __BT_NOEXCEPT; /*! @brief @@ -763,7 +763,7 @@ existing \bt_p{_dst} reference. static inline const bt_component_class * bt_component_class_sink_as_component_class_const( - const bt_component_class_sink *component_class) + const bt_component_class_sink *component_class) __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_component_class, component_class); } @@ -791,7 +791,7 @@ bt_component_class_sink_as_component_class_const( Decrements the reference count of a sink component class. */ extern void bt_component_class_sink_get_ref( - const bt_component_class_sink *component_class); + const bt_component_class_sink *component_class) __BT_NOEXCEPT; /*! @brief @@ -809,7 +809,7 @@ extern void bt_component_class_sink_get_ref( Increments the reference count of a sink component class. */ extern void bt_component_class_sink_put_ref( - const bt_component_class_sink *component_class); + const bt_component_class_sink *component_class) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/graph/component-descriptor-set.h b/include/babeltrace2/graph/component-descriptor-set.h index 9c929a34..918bff40 100644 --- a/include/babeltrace2/graph/component-descriptor-set.h +++ b/include/babeltrace2/graph/component-descriptor-set.h @@ -95,7 +95,8 @@ bt_component_descriptor_set_add_descriptor_with_initialize_method_data(). @returns New component descriptor set reference, or \c NULL on memory error. */ -extern bt_component_descriptor_set *bt_component_descriptor_set_create(void); +extern bt_component_descriptor_set *bt_component_descriptor_set_create(void) + __BT_NOEXCEPT; /*! @brief @@ -134,7 +135,7 @@ extern bt_component_descriptor_set_add_descriptor_status bt_component_descriptor_set_add_descriptor( bt_component_descriptor_set *component_descriptor_set, const bt_component_class *component_class, - const bt_value *params); + const bt_value *params) __BT_NOEXCEPT; /*! @brief @@ -180,7 +181,8 @@ extern bt_component_descriptor_set_add_descriptor_status bt_component_descriptor_set_add_descriptor_with_initialize_method_data( bt_component_descriptor_set *component_descriptor_set, const bt_component_class *component_class, - const bt_value *params, void *initialize_method_data); + const bt_value *params, + void *initialize_method_data) __BT_NOEXCEPT; /*! @} */ @@ -205,7 +207,8 @@ bt_component_descriptor_set_add_descriptor_with_initialize_method_data( Decrements the reference count of a component descriptor set. */ extern void bt_component_descriptor_set_get_ref( - const bt_component_descriptor_set *component_descriptor_set); + const bt_component_descriptor_set *component_descriptor_set) + __BT_NOEXCEPT; /*! @brief @@ -223,7 +226,8 @@ extern void bt_component_descriptor_set_get_ref( Increments the reference count of a component descriptor set. */ extern void bt_component_descriptor_set_put_ref( - const bt_component_descriptor_set *component_descriptor_set); + const bt_component_descriptor_set *component_descriptor_set) + __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/graph/component.h b/include/babeltrace2/graph/component.h index 8d2a0a4e..1b192590 100644 --- a/include/babeltrace2/graph/component.h +++ b/include/babeltrace2/graph/component.h @@ -240,7 +240,7 @@ A component has the following common properties: Returns whether or not a component is a \bt_sink_comp. */ extern bt_component_class_type bt_component_get_class_type( - const bt_component *component); + const bt_component *component) __BT_NOEXCEPT; /*! @brief @@ -259,7 +259,7 @@ extern bt_component_class_type bt_component_get_class_type( Returns the type enumerator of a component's class. */ static inline -bt_bool bt_component_is_source(const bt_component *component) +bt_bool bt_component_is_source(const bt_component *component) __BT_NOEXCEPT { return bt_component_get_class_type(component) == BT_COMPONENT_CLASS_TYPE_SOURCE; @@ -282,7 +282,7 @@ bt_bool bt_component_is_source(const bt_component *component) Returns the type enumerator of a component's class. */ static inline -bt_bool bt_component_is_filter(const bt_component *component) +bt_bool bt_component_is_filter(const bt_component *component) __BT_NOEXCEPT { return bt_component_get_class_type(component) == BT_COMPONENT_CLASS_TYPE_FILTER; @@ -305,7 +305,7 @@ bt_bool bt_component_is_filter(const bt_component *component) Returns the type enumerator of a component's class. */ static inline -bt_bool bt_component_is_sink(const bt_component *component) +bt_bool bt_component_is_sink(const bt_component *component) __BT_NOEXCEPT { return bt_component_get_class_type(component) == BT_COMPONENT_CLASS_TYPE_SINK; @@ -332,7 +332,7 @@ bt_bool bt_component_is_sink(const bt_component *component) @bt_pre_not_null{component} */ extern const bt_component_class *bt_component_borrow_class_const( - const bt_component *component); + const bt_component *component) __BT_NOEXCEPT; /*! @} */ @@ -360,7 +360,8 @@ See the \ref api-comp-prop-name "name" property. @bt_pre_not_null{component} */ -extern const char *bt_component_get_name(const bt_component *component); +extern const char *bt_component_get_name(const bt_component *component) + __BT_NOEXCEPT; /*! @brief @@ -378,7 +379,7 @@ See the \ref api-comp-prop-log-lvl "logging level" property. @bt_pre_not_null{component} */ extern bt_logging_level bt_component_get_logging_level( - const bt_component *component); + const bt_component *component) __BT_NOEXCEPT; /*! @} */ @@ -402,7 +403,7 @@ extern bt_logging_level bt_component_get_logging_level( @sa bt_component_put_ref() — Decrements the reference count of a component. */ -extern void bt_component_get_ref(const bt_component *component); +extern void bt_component_get_ref(const bt_component *component) __BT_NOEXCEPT; /*! @brief @@ -419,7 +420,7 @@ extern void bt_component_get_ref(const bt_component *component); @sa bt_component_get_ref() — Increments the reference count of a component. */ -extern void bt_component_put_ref(const bt_component *component); +extern void bt_component_put_ref(const bt_component *component) __BT_NOEXCEPT; /*! @brief @@ -495,7 +496,7 @@ This macro effectively moves a component reference from the expression */ extern const bt_component_class_source * bt_component_source_borrow_class_const( - const bt_component_source *component); + const bt_component_source *component) __BT_NOEXCEPT; /*! @} */ @@ -521,7 +522,7 @@ bt_component_source_borrow_class_const( */ static inline const bt_component *bt_component_source_as_component_const( - const bt_component_source *component) + const bt_component_source *component) __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_component, component); } @@ -547,7 +548,7 @@ const bt_component *bt_component_source_as_component_const( @bt_pre_not_null{component} */ extern uint64_t bt_component_source_get_output_port_count( - const bt_component_source *component); + const bt_component_source *component) __BT_NOEXCEPT; /*! @brief @@ -580,7 +581,8 @@ extern uint64_t bt_component_source_get_output_port_count( */ extern const bt_port_output * bt_component_source_borrow_output_port_by_index_const( - const bt_component_source *component, uint64_t index); + const bt_component_source *component, + uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -610,7 +612,8 @@ returns \c NULL. */ extern const bt_port_output * bt_component_source_borrow_output_port_by_name_const( - const bt_component_source *component, const char *name); + const bt_component_source *component, + const char *name) __BT_NOEXCEPT; /*! @} */ @@ -635,7 +638,7 @@ bt_component_source_borrow_output_port_by_name_const( Decrements the reference count of a source component. */ extern void bt_component_source_get_ref( - const bt_component_source *component); + const bt_component_source *component) __BT_NOEXCEPT; /*! @brief @@ -653,7 +656,7 @@ extern void bt_component_source_get_ref( Increments the reference count of a source component. */ extern void bt_component_source_put_ref( - const bt_component_source *component); + const bt_component_source *component) __BT_NOEXCEPT; /*! @brief @@ -729,7 +732,7 @@ existing \bt_p{_dst} reference. */ extern const bt_component_class_filter * bt_component_filter_borrow_class_const( - const bt_component_filter *component); + const bt_component_filter *component) __BT_NOEXCEPT; /*! @} */ @@ -755,7 +758,7 @@ bt_component_filter_borrow_class_const( */ static inline const bt_component *bt_component_filter_as_component_const( - const bt_component_filter *component) + const bt_component_filter *component) __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_component, component); } @@ -781,7 +784,7 @@ const bt_component *bt_component_filter_as_component_const( @bt_pre_not_null{component} */ extern uint64_t bt_component_filter_get_input_port_count( - const bt_component_filter *component); + const bt_component_filter *component) __BT_NOEXCEPT; /*! @brief @@ -814,7 +817,8 @@ extern uint64_t bt_component_filter_get_input_port_count( */ extern const bt_port_input * bt_component_filter_borrow_input_port_by_index_const( - const bt_component_filter *component, uint64_t index); + const bt_component_filter *component, uint64_t index) + __BT_NOEXCEPT; /*! @brief @@ -844,7 +848,8 @@ returns \c NULL. */ extern const bt_port_input * bt_component_filter_borrow_input_port_by_name_const( - const bt_component_filter *component, const char *name); + const bt_component_filter *component, const char *name) + __BT_NOEXCEPT; /*! @brief @@ -860,7 +865,7 @@ bt_component_filter_borrow_input_port_by_name_const( @bt_pre_not_null{component} */ extern uint64_t bt_component_filter_get_output_port_count( - const bt_component_filter *component); + const bt_component_filter *component) __BT_NOEXCEPT; /*! @brief @@ -893,7 +898,8 @@ extern uint64_t bt_component_filter_get_output_port_count( */ extern const bt_port_output * bt_component_filter_borrow_output_port_by_index_const( - const bt_component_filter *component, uint64_t index); + const bt_component_filter *component, uint64_t index) + __BT_NOEXCEPT; /*! @brief @@ -923,7 +929,8 @@ returns \c NULL. */ extern const bt_port_output * bt_component_filter_borrow_output_port_by_name_const( - const bt_component_filter *component, const char *name); + const bt_component_filter *component, const char *name) + __BT_NOEXCEPT; /*! @} */ @@ -948,7 +955,7 @@ bt_component_filter_borrow_output_port_by_name_const( Decrements the reference count of a filter component. */ extern void bt_component_filter_get_ref( - const bt_component_filter *component); + const bt_component_filter *component) __BT_NOEXCEPT; /*! @brief @@ -966,7 +973,7 @@ extern void bt_component_filter_get_ref( Increments the reference count of a filter component. */ extern void bt_component_filter_put_ref( - const bt_component_filter *component); + const bt_component_filter *component) __BT_NOEXCEPT; /*! @brief @@ -1042,7 +1049,7 @@ existing \bt_p{_dst} reference. */ extern const bt_component_class_sink * bt_component_sink_borrow_class_const( - const bt_component_sink *component); + const bt_component_sink *component) __BT_NOEXCEPT; /*! @} */ @@ -1068,7 +1075,7 @@ bt_component_sink_borrow_class_const( */ static inline const bt_component *bt_component_sink_as_component_const( - const bt_component_sink *component) + const bt_component_sink *component) __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_component, component); } @@ -1094,7 +1101,7 @@ const bt_component *bt_component_sink_as_component_const( @bt_pre_not_null{component} */ extern uint64_t bt_component_sink_get_input_port_count( - const bt_component_sink *component); + const bt_component_sink *component) __BT_NOEXCEPT; /*! @brief @@ -1127,7 +1134,8 @@ extern uint64_t bt_component_sink_get_input_port_count( */ extern const bt_port_input * bt_component_sink_borrow_input_port_by_index_const( - const bt_component_sink *component, uint64_t index); + const bt_component_sink *component, uint64_t index) + __BT_NOEXCEPT; /*! @brief @@ -1157,7 +1165,8 @@ returns \c NULL. */ extern const bt_port_input * bt_component_sink_borrow_input_port_by_name_const( - const bt_component_sink *component, const char *name); + const bt_component_sink *component, const char *name) + __BT_NOEXCEPT; /*! @} */ @@ -1182,7 +1191,7 @@ bt_component_sink_borrow_input_port_by_name_const( Decrements the reference count of a sink component. */ extern void bt_component_sink_get_ref( - const bt_component_sink *component); + const bt_component_sink *component) __BT_NOEXCEPT; /*! @brief @@ -1200,7 +1209,7 @@ extern void bt_component_sink_get_ref( Increments the reference count of a sink component. */ extern void bt_component_sink_put_ref( - const bt_component_sink *component); + const bt_component_sink *component) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/graph/connection.h b/include/babeltrace2/graph/connection.h index 53e6c890..8400522f 100644 --- a/include/babeltrace2/graph/connection.h +++ b/include/babeltrace2/graph/connection.h @@ -74,7 +74,7 @@ bt_connection_borrow_downstream_port_const(). @bt_pre_not_null{connection} */ extern const bt_port_input *bt_connection_borrow_downstream_port_const( - const bt_connection *connection); + const bt_connection *connection) __BT_NOEXCEPT; /*! @brief @@ -90,7 +90,7 @@ extern const bt_port_input *bt_connection_borrow_downstream_port_const( @bt_pre_not_null{connection} */ extern const bt_port_output *bt_connection_borrow_upstream_port_const( - const bt_connection *connection); + const bt_connection *connection) __BT_NOEXCEPT; /*! @} */ @@ -114,7 +114,8 @@ extern const bt_port_output *bt_connection_borrow_upstream_port_const( @sa bt_connection_put_ref() — Decrements the reference count of a connection. */ -extern void bt_connection_get_ref(const bt_connection *connection); +extern void bt_connection_get_ref(const bt_connection *connection) + __BT_NOEXCEPT; /*! @brief @@ -131,7 +132,8 @@ extern void bt_connection_get_ref(const bt_connection *connection); @sa bt_connection_get_ref() — Increments the reference count of a connection. */ -extern void bt_connection_put_ref(const bt_connection *connection); +extern void bt_connection_put_ref(const bt_connection *connection) + __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/graph/graph.h b/include/babeltrace2/graph/graph.h index f9359dda..0f80a1e1 100644 --- a/include/babeltrace2/graph/graph.h +++ b/include/babeltrace2/graph/graph.h @@ -560,7 +560,7 @@ default interrupter with bt_graph_borrow_default_interrupter(). @pre \bt_p{mip_version} is 0. */ -extern bt_graph *bt_graph_create(uint64_t mip_version); +extern bt_graph *bt_graph_create(uint64_t mip_version) __BT_NOEXCEPT; /*! @} */ @@ -604,7 +604,7 @@ bt_graph_add_source_component(bt_graph *graph, const bt_component_class_source *component_class, const char *name, const bt_value *params, bt_logging_level logging_level, - const bt_component_source **component); + const bt_component_source **component) __BT_NOEXCEPT; /*! @brief @@ -685,7 +685,7 @@ bt_graph_add_source_component_with_initialize_method_data( const bt_component_class_source *component_class, const char *name, const bt_value *params, void *initialize_method_data, bt_logging_level logging_level, - const bt_component_source **component); + const bt_component_source **component) __BT_NOEXCEPT; /*! @brief @@ -697,7 +697,7 @@ bt_graph_add_filter_component(bt_graph *graph, const bt_component_class_filter *component_class, const char *name, const bt_value *params, bt_logging_level logging_level, - const bt_component_filter **component); + const bt_component_filter **component) __BT_NOEXCEPT; /*! @brief @@ -778,7 +778,7 @@ bt_graph_add_filter_component_with_initialize_method_data( const bt_component_class_filter *component_class, const char *name, const bt_value *params, void *initialize_method_data, bt_logging_level logging_level, - const bt_component_filter **component); + const bt_component_filter **component) __BT_NOEXCEPT; /*! @brief @@ -790,7 +790,7 @@ bt_graph_add_sink_component( bt_graph *graph, const bt_component_class_sink *component_class, const char *name, const bt_value *params, bt_logging_level logging_level, - const bt_component_sink **component); + const bt_component_sink **component) __BT_NOEXCEPT; /*! @brief @@ -870,7 +870,7 @@ bt_graph_add_sink_component_with_initialize_method_data( bt_graph *graph, const bt_component_class_sink *component_class, const char *name, const bt_value *params, void *initialize_method_data, bt_logging_level logging_level, - const bt_component_sink **component); + const bt_component_sink **component) __BT_NOEXCEPT; /*! @} */ @@ -1130,7 +1130,7 @@ bt_graph_add_simple_sink_component(bt_graph *graph, const char *name, bt_graph_simple_sink_component_initialize_func initialize_func, bt_graph_simple_sink_component_consume_func consume_func, bt_graph_simple_sink_component_finalize_func finalize_func, - void *user_data, const bt_component_sink **component); + void *user_data, const bt_component_sink **component) __BT_NOEXCEPT; /*! @} */ @@ -1219,7 +1219,7 @@ this function. extern bt_graph_connect_ports_status bt_graph_connect_ports(bt_graph *graph, const bt_port_output *upstream_port, const bt_port_input *downstream_port, - const bt_connection **connection); + const bt_connection **connection) __BT_NOEXCEPT; /*! @} */ @@ -1335,7 +1335,7 @@ and what you can and cannot do with a configured graph. Calls a single trace processing graph's sink component's consuming method once. */ -extern bt_graph_run_status bt_graph_run(bt_graph *graph); +extern bt_graph_run_status bt_graph_run(bt_graph *graph) __BT_NOEXCEPT; /*! @brief @@ -1443,7 +1443,7 @@ and what you can and cannot do with a configured graph. Runs a trace processing graph, making all its sink components consume in a round robin fashion. */ -extern bt_graph_run_once_status bt_graph_run_once(bt_graph *graph); +extern bt_graph_run_once_status bt_graph_run_once(bt_graph *graph) __BT_NOEXCEPT; /*! @} */ @@ -1517,7 +1517,7 @@ graph's interrupters is set. If so, bt_graph_run() returns Borrows the default interrupter from a trace processing graph. */ extern bt_graph_add_interrupter_status bt_graph_add_interrupter(bt_graph *graph, - const bt_interrupter *interrupter); + const bt_interrupter *interrupter) __BT_NOEXCEPT; /*! @brief @@ -1539,7 +1539,8 @@ extern bt_graph_add_interrupter_status bt_graph_add_interrupter(bt_graph *graph, @sa bt_graph_add_interrupter() — Adds an interrupter to a trace processing graph. */ -extern bt_interrupter *bt_graph_borrow_default_interrupter(bt_graph *graph); +extern bt_interrupter *bt_graph_borrow_default_interrupter(bt_graph *graph) + __BT_NOEXCEPT; /*! @} */ @@ -1668,7 +1669,7 @@ extern bt_graph_add_listener_status bt_graph_add_filter_component_input_port_added_listener( bt_graph *graph, bt_graph_filter_component_input_port_added_listener_func user_func, - void *user_data, bt_listener_id *listener_id); + void *user_data, bt_listener_id *listener_id) __BT_NOEXCEPT; /*! @brief @@ -1744,7 +1745,7 @@ extern bt_graph_add_listener_status bt_graph_add_sink_component_input_port_added_listener( bt_graph *graph, bt_graph_sink_component_input_port_added_listener_func user_func, - void *user_data, bt_listener_id *listener_id); + void *user_data, bt_listener_id *listener_id) __BT_NOEXCEPT; /*! @brief @@ -1820,7 +1821,7 @@ extern bt_graph_add_listener_status bt_graph_add_source_component_output_port_added_listener( bt_graph *graph, bt_graph_source_component_output_port_added_listener_func user_func, - void *user_data, bt_listener_id *listener_id); + void *user_data, bt_listener_id *listener_id) __BT_NOEXCEPT; /*! @brief @@ -1896,7 +1897,7 @@ extern bt_graph_add_listener_status bt_graph_add_filter_component_output_port_added_listener( bt_graph *graph, bt_graph_filter_component_output_port_added_listener_func user_func, - void *user_data, bt_listener_id *listener_id); + void *user_data, bt_listener_id *listener_id) __BT_NOEXCEPT; /*! @} */ @@ -1920,7 +1921,7 @@ bt_graph_add_filter_component_output_port_added_listener( @sa bt_graph_put_ref() — Decrements the reference count of a trace processing graph. */ -extern void bt_graph_get_ref(const bt_graph *graph); +extern void bt_graph_get_ref(const bt_graph *graph) __BT_NOEXCEPT; /*! @brief @@ -1937,7 +1938,7 @@ extern void bt_graph_get_ref(const bt_graph *graph); @sa bt_graph_get_ref() — Increments the reference count of a trace processing graph. */ -extern void bt_graph_put_ref(const bt_graph *graph); +extern void bt_graph_put_ref(const bt_graph *graph) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/graph/interrupter.h b/include/babeltrace2/graph/interrupter.h index 4290dca7..1c8729b4 100644 --- a/include/babeltrace2/graph/interrupter.h +++ b/include/babeltrace2/graph/interrupter.h @@ -108,7 +108,7 @@ On success, the returned interrupter is \em not set @returns New interrupter reference, or \c NULL on memory error. */ -extern bt_interrupter *bt_interrupter_create(void); +extern bt_interrupter *bt_interrupter_create(void) __BT_NOEXCEPT; /*! @} */ @@ -134,7 +134,7 @@ After you call this function, bt_interrupter_is_set() returns @sa bt_interrupter_is_set() — Returns whether or not an interrupter is set. */ -extern void bt_interrupter_set(bt_interrupter *interrupter); +extern void bt_interrupter_set(bt_interrupter *interrupter) __BT_NOEXCEPT; /*! @brief @@ -153,7 +153,7 @@ After you call this function, bt_interrupter_is_set() returns @sa bt_interrupter_is_set() — Returns whether or not an interrupter is set. */ -extern void bt_interrupter_reset(bt_interrupter *interrupter); +extern void bt_interrupter_reset(bt_interrupter *interrupter) __BT_NOEXCEPT; /*! @brief @@ -172,7 +172,8 @@ extern void bt_interrupter_reset(bt_interrupter *interrupter); @sa bt_interrupter_reset() — Resets an interrupter. */ -extern bt_bool bt_interrupter_is_set(const bt_interrupter *interrupter); +extern bt_bool bt_interrupter_is_set(const bt_interrupter *interrupter) + __BT_NOEXCEPT; /*! @} */ @@ -196,7 +197,8 @@ extern bt_bool bt_interrupter_is_set(const bt_interrupter *interrupter); @sa bt_interrupter_put_ref() — Decrements the reference count of an interrupter. */ -extern void bt_interrupter_get_ref(const bt_interrupter *interrupter); +extern void bt_interrupter_get_ref(const bt_interrupter *interrupter) + __BT_NOEXCEPT; /*! @brief @@ -213,7 +215,8 @@ extern void bt_interrupter_get_ref(const bt_interrupter *interrupter); @sa bt_interrupter_get_ref() — Increments the reference count of an interrupter. */ -extern void bt_interrupter_put_ref(const bt_interrupter *interrupter); +extern void bt_interrupter_put_ref(const bt_interrupter *interrupter) + __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/graph/message-iterator-class.h b/include/babeltrace2/graph/message-iterator-class.h index 94daac09..5a409caf 100644 --- a/include/babeltrace2/graph/message-iterator-class.h +++ b/include/babeltrace2/graph/message-iterator-class.h @@ -977,7 +977,8 @@ typedef bt_message_iterator_class_seek_ns_from_origin_method_status */ extern bt_message_iterator_class * bt_message_iterator_class_create( - bt_message_iterator_class_next_method next_method); + bt_message_iterator_class_next_method next_method) + __BT_NOEXCEPT; /*! @} */ @@ -1022,7 +1023,7 @@ See the \ref api-msg-iter-cls-meth-fini "finalize" method. extern bt_message_iterator_class_set_method_status bt_message_iterator_class_set_finalize_method( bt_message_iterator_class *message_iterator_class, - bt_message_iterator_class_finalize_method method); + bt_message_iterator_class_finalize_method method) __BT_NOEXCEPT; /*! @brief @@ -1047,7 +1048,8 @@ See the \ref api-msg-iter-cls-meth-init "initialize" method. extern bt_message_iterator_class_set_method_status bt_message_iterator_class_set_initialize_method( bt_message_iterator_class *message_iterator_class, - bt_message_iterator_class_initialize_method method); + bt_message_iterator_class_initialize_method method) + __BT_NOEXCEPT; /*! @brief @@ -1084,7 +1086,8 @@ extern bt_message_iterator_class_set_method_status bt_message_iterator_class_set_seek_beginning_methods( bt_message_iterator_class *message_iterator_class, bt_message_iterator_class_seek_beginning_method seek_method, - bt_message_iterator_class_can_seek_beginning_method can_seek_method); + bt_message_iterator_class_can_seek_beginning_method can_seek_method) + __BT_NOEXCEPT; /*! @brief @@ -1123,7 +1126,8 @@ extern bt_message_iterator_class_set_method_status bt_message_iterator_class_set_seek_ns_from_origin_methods( bt_message_iterator_class *message_iterator_class, bt_message_iterator_class_seek_ns_from_origin_method seek_method, - bt_message_iterator_class_can_seek_ns_from_origin_method can_seek_method); + bt_message_iterator_class_can_seek_ns_from_origin_method can_seek_method) + __BT_NOEXCEPT; /*! @} */ @@ -1148,7 +1152,8 @@ bt_message_iterator_class_set_seek_ns_from_origin_methods( Decrements the reference count of a message iterator class. */ extern void bt_message_iterator_class_get_ref( - const bt_message_iterator_class *message_iterator_class); + const bt_message_iterator_class *message_iterator_class) + __BT_NOEXCEPT; /*! @brief @@ -1166,7 +1171,8 @@ extern void bt_message_iterator_class_get_ref( Increments the reference count of a message iterator class. */ extern void bt_message_iterator_class_put_ref( - const bt_message_iterator_class *message_iterator_class); + const bt_message_iterator_class *message_iterator_class) + __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/graph/message-iterator.h b/include/babeltrace2/graph/message-iterator.h index 0b6d102c..1a39dfc5 100644 --- a/include/babeltrace2/graph/message-iterator.h +++ b/include/babeltrace2/graph/message-iterator.h @@ -264,7 +264,7 @@ extern bt_message_iterator_create_from_message_iterator_status bt_message_iterator_create_from_message_iterator( bt_self_message_iterator *self_message_iterator, bt_self_component_port_input *port, - bt_message_iterator **message_iterator); + bt_message_iterator **message_iterator) __BT_NOEXCEPT; /*! @brief @@ -328,7 +328,7 @@ extern bt_message_iterator_create_from_sink_component_status bt_message_iterator_create_from_sink_component( bt_self_component_sink *self_component_sink, bt_self_component_port_input *port, - bt_message_iterator **message_iterator); + bt_message_iterator **message_iterator) __BT_NOEXCEPT; /*! @} */ @@ -353,7 +353,7 @@ bt_message_iterator_create_from_sink_component( */ extern bt_component * bt_message_iterator_borrow_component( - bt_message_iterator *message_iterator); + bt_message_iterator *message_iterator) __BT_NOEXCEPT; /*! @} */ @@ -454,7 +454,8 @@ messages. */ extern bt_message_iterator_next_status bt_message_iterator_next(bt_message_iterator *message_iterator, - bt_message_array_const *messages, uint64_t *count); + bt_message_array_const *messages, uint64_t *count) + __BT_NOEXCEPT; /*! @} */ @@ -530,7 +531,7 @@ call bt_message_iterator_seek_beginning(). extern bt_message_iterator_can_seek_beginning_status bt_message_iterator_can_seek_beginning( bt_message_iterator *message_iterator, - bt_bool *can_seek_beginning); + bt_bool *can_seek_beginning) __BT_NOEXCEPT; /*! @brief @@ -596,7 +597,7 @@ without performing any other \ref api-msg-iter-ops "operation" on */ extern bt_message_iterator_seek_beginning_status bt_message_iterator_seek_beginning( - bt_message_iterator *message_iterator); + bt_message_iterator *message_iterator) __BT_NOEXCEPT; /*! @brief @@ -673,7 +674,8 @@ call bt_message_iterator_seek_ns_from_origin(). extern bt_message_iterator_can_seek_ns_from_origin_status bt_message_iterator_can_seek_ns_from_origin( bt_message_iterator *message_iterator, - int64_t ns_from_origin, bt_bool *can_seek_ns_from_origin); + int64_t ns_from_origin, bt_bool *can_seek_ns_from_origin) + __BT_NOEXCEPT; /*! @brief @@ -745,7 +747,7 @@ without performing any other \ref api-msg-iter-ops "operation" on extern bt_message_iterator_seek_ns_from_origin_status bt_message_iterator_seek_ns_from_origin( bt_message_iterator *message_iterator, - int64_t ns_from_origin); + int64_t ns_from_origin) __BT_NOEXCEPT; /*! @} */ @@ -773,7 +775,7 @@ message sequence have some \bt_cs. */ extern bt_bool bt_message_iterator_can_seek_forward( - bt_message_iterator *message_iterator); + bt_message_iterator *message_iterator) __BT_NOEXCEPT; /*! @} */ @@ -798,7 +800,7 @@ bt_message_iterator_can_seek_forward( Decrements the reference count of a message iterator. */ extern void bt_message_iterator_get_ref( - const bt_message_iterator *message_iterator); + const bt_message_iterator *message_iterator) __BT_NOEXCEPT; /*! @brief @@ -816,7 +818,7 @@ extern void bt_message_iterator_get_ref( Increments the reference count of a message iterator. */ extern void bt_message_iterator_put_ref( - const bt_message_iterator *message_iterator); + const bt_message_iterator *message_iterator) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/graph/message.h b/include/babeltrace2/graph/message.h index 00d7dba0..cdd125fd 100644 --- a/include/babeltrace2/graph/message.h +++ b/include/babeltrace2/graph/message.h @@ -1025,7 +1025,8 @@ typedef enum bt_message_type { @bt_pre_not_null{message} */ -extern bt_message_type bt_message_get_type(const bt_message *message); +extern bt_message_type bt_message_get_type(const bt_message *message) + __BT_NOEXCEPT; /*! @} */ @@ -1099,7 +1100,7 @@ property values: extern bt_message *bt_message_stream_beginning_create( bt_self_message_iterator *self_message_iterator, - const bt_stream *stream); + const bt_stream *stream) __BT_NOEXCEPT; /*! @brief @@ -1124,7 +1125,7 @@ See the \ref api-msg-sb-prop-stream "stream" property. \c const version of this function. */ extern bt_stream *bt_message_stream_beginning_borrow_stream( - bt_message *message); + bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -1134,7 +1135,7 @@ extern bt_stream *bt_message_stream_beginning_borrow_stream( See bt_message_stream_beginning_borrow_stream(). */ extern const bt_stream *bt_message_stream_beginning_borrow_stream_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -1162,7 +1163,7 @@ See the \ref api-msg-sb-prop-cs "default clock snapshot" property. */ extern void bt_message_stream_beginning_set_default_clock_snapshot( - bt_message *message, uint64_t value); + bt_message *message, uint64_t value) __BT_NOEXCEPT; /*! @brief @@ -1198,7 +1199,7 @@ See the \ref api-msg-sb-prop-cs "default clock snapshot" property. extern bt_message_stream_clock_snapshot_state bt_message_stream_beginning_borrow_default_clock_snapshot_const( const bt_message *message, - const bt_clock_snapshot **clock_snapshot); + const bt_clock_snapshot **clock_snapshot) __BT_NOEXCEPT; /*! @brief @@ -1230,7 +1231,7 @@ bt_stream_class_borrow_default_clock_class_const( */ extern const bt_clock_class * bt_message_stream_beginning_borrow_stream_class_default_clock_class_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @} */ @@ -1276,7 +1277,7 @@ property values: extern bt_message *bt_message_stream_end_create( bt_self_message_iterator *self_message_iterator, - const bt_stream *stream); + const bt_stream *stream) __BT_NOEXCEPT; /*! @brief @@ -1301,7 +1302,7 @@ See the \ref api-msg-se-prop-stream "stream" property. \c const version of this function. */ extern bt_stream *bt_message_stream_end_borrow_stream( - bt_message *message); + bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -1311,7 +1312,7 @@ extern bt_stream *bt_message_stream_end_borrow_stream( See bt_message_stream_end_borrow_stream(). */ extern const bt_stream *bt_message_stream_end_borrow_stream_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -1339,7 +1340,7 @@ See the \ref api-msg-se-prop-cs "default clock snapshot" property. */ extern void bt_message_stream_end_set_default_clock_snapshot( - bt_message *message, uint64_t value); + bt_message *message, uint64_t value) __BT_NOEXCEPT; /*! @brief @@ -1375,7 +1376,7 @@ See the \ref api-msg-se-prop-cs "default clock snapshot" property. extern bt_message_stream_clock_snapshot_state bt_message_stream_end_borrow_default_clock_snapshot_const( const bt_message *message, - const bt_clock_snapshot **clock_snapshot); + const bt_clock_snapshot **clock_snapshot) __BT_NOEXCEPT; /*! @brief @@ -1407,7 +1408,7 @@ bt_stream_class_borrow_default_clock_class_const( */ extern const bt_clock_class * bt_message_stream_end_borrow_stream_class_default_clock_class_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @} */ @@ -1494,7 +1495,7 @@ extern bt_message *bt_message_event_create( bt_self_message_iterator *self_message_iterator, const bt_event_class *event_class, - const bt_stream *stream); + const bt_stream *stream) __BT_NOEXCEPT; /*! @brief @@ -1578,7 +1579,8 @@ extern bt_message *bt_message_event_create_with_default_clock_snapshot( bt_self_message_iterator *self_message_iterator, const bt_event_class *event_class, - const bt_stream *stream, uint64_t clock_snapshot_value); + const bt_stream *stream, uint64_t clock_snapshot_value) + __BT_NOEXCEPT; /*! @brief @@ -1663,7 +1665,7 @@ extern bt_message *bt_message_event_create_with_packet( bt_self_message_iterator *self_message_iterator, const bt_event_class *event_class, - const bt_packet *packet); + const bt_packet *packet) __BT_NOEXCEPT; /*! @brief @@ -1752,7 +1754,8 @@ extern bt_message *bt_message_event_create_with_packet_and_default_clock_snapshot( bt_self_message_iterator *self_message_iterator, const bt_event_class *event_class, - const bt_packet *packet, uint64_t clock_snapshot_value); + const bt_packet *packet, uint64_t clock_snapshot_value) + __BT_NOEXCEPT; /*! @brief @@ -1776,8 +1779,8 @@ See the \ref api-msg-ev-prop-ev "event" property. @sa bt_message_event_borrow_event_const() — \c const version of this function. */ -extern bt_event *bt_message_event_borrow_event( - bt_message *message); +extern bt_event *bt_message_event_borrow_event(bt_message *message) + __BT_NOEXCEPT; /*! @brief @@ -1787,7 +1790,7 @@ extern bt_event *bt_message_event_borrow_event( See bt_message_event_borrow_event(). */ extern const bt_event *bt_message_event_borrow_event_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -1808,7 +1811,8 @@ See the \ref api-msg-ev-prop-cs "default clock snapshot" property. \ref api-tir-stream-cls-prop-def-clock-cls "default clock class". */ extern const bt_clock_snapshot * -bt_message_event_borrow_default_clock_snapshot_const(const bt_message *message); +bt_message_event_borrow_default_clock_snapshot_const(const bt_message *message) + __BT_NOEXCEPT; /*! @brief @@ -1841,7 +1845,7 @@ bt_stream_class_borrow_default_clock_class_const( */ extern const bt_clock_class * bt_message_event_borrow_stream_class_default_clock_class_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @} */ @@ -1909,7 +1913,7 @@ property values: extern bt_message *bt_message_packet_beginning_create( bt_self_message_iterator *self_message_iterator, - const bt_packet *packet); + const bt_packet *packet) __BT_NOEXCEPT; /*! @brief @@ -1974,7 +1978,8 @@ property values: extern bt_message *bt_message_packet_beginning_create_with_default_clock_snapshot( bt_self_message_iterator *self_message_iterator, - const bt_packet *packet, uint64_t clock_snapshot_value); + const bt_packet *packet, uint64_t clock_snapshot_value) + __BT_NOEXCEPT; /*! @brief @@ -1999,7 +2004,7 @@ See the \ref api-msg-pb-prop-pkt "packet" property. \c const version of this function. */ extern bt_packet *bt_message_packet_beginning_borrow_packet( - bt_message *message); + bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2009,7 +2014,7 @@ extern bt_packet *bt_message_packet_beginning_borrow_packet( See bt_message_packet_beginning_borrow_packet(). */ extern const bt_packet *bt_message_packet_beginning_borrow_packet_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2032,7 +2037,7 @@ See the \ref api-msg-pb-prop-cs "default clock snapshot" property. */ extern const bt_clock_snapshot * bt_message_packet_beginning_borrow_default_clock_snapshot_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2065,7 +2070,7 @@ bt_stream_class_borrow_default_clock_class_const( */ extern const bt_clock_class * bt_message_packet_beginning_borrow_stream_class_default_clock_class_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @} */ @@ -2132,7 +2137,7 @@ property values: extern bt_message *bt_message_packet_end_create( bt_self_message_iterator *self_message_iterator, - const bt_packet *packet); + const bt_packet *packet) __BT_NOEXCEPT; /*! @brief @@ -2197,7 +2202,8 @@ property values: extern bt_message *bt_message_packet_end_create_with_default_clock_snapshot( bt_self_message_iterator *self_message_iterator, - const bt_packet *packet, uint64_t clock_snapshot_value); + const bt_packet *packet, uint64_t clock_snapshot_value) + __BT_NOEXCEPT; /*! @brief @@ -2222,7 +2228,7 @@ See the \ref api-msg-pe-prop-pkt "packet" property. \c const version of this function. */ extern bt_packet *bt_message_packet_end_borrow_packet( - bt_message *message); + bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2232,7 +2238,7 @@ extern bt_packet *bt_message_packet_end_borrow_packet( See bt_message_packet_end_borrow_packet(). */ extern const bt_packet *bt_message_packet_end_borrow_packet_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2255,7 +2261,7 @@ See the \ref api-msg-pe-prop-cs "default clock snapshot" property. */ extern const bt_clock_snapshot * bt_message_packet_end_borrow_default_clock_snapshot_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2288,7 +2294,7 @@ bt_stream_class_borrow_default_clock_class_const( */ extern const bt_clock_class * bt_message_packet_end_borrow_stream_class_default_clock_class_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @} */ @@ -2357,7 +2363,7 @@ property values: */ extern bt_message *bt_message_discarded_events_create( bt_self_message_iterator *self_message_iterator, - const bt_stream *stream); + const bt_stream *stream) __BT_NOEXCEPT; /*! @brief @@ -2430,7 +2436,8 @@ extern bt_message *bt_message_discarded_events_create_with_default_clock_snapsho bt_self_message_iterator *self_message_iterator, const bt_stream *stream, uint64_t beginning_clock_snapshot_value, - uint64_t end_clock_snapshot_value); + uint64_t end_clock_snapshot_value) + __BT_NOEXCEPT; /*! @brief @@ -2455,7 +2462,7 @@ See the \ref api-msg-disc-ev-prop-stream "stream" property. \c const version of this function. */ extern bt_stream *bt_message_discarded_events_borrow_stream( - bt_message *message); + bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2465,7 +2472,8 @@ extern bt_stream *bt_message_discarded_events_borrow_stream( See bt_message_discarded_events_borrow_stream(). */ extern const bt_stream * -bt_message_discarded_events_borrow_stream_const(const bt_message *message); +bt_message_discarded_events_borrow_stream_const(const bt_message *message) + __BT_NOEXCEPT; /*! @brief @@ -2492,7 +2500,7 @@ property. */ extern const bt_clock_snapshot * bt_message_discarded_events_borrow_beginning_default_clock_snapshot_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2519,7 +2527,7 @@ property. */ extern const bt_clock_snapshot * bt_message_discarded_events_borrow_end_default_clock_snapshot_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2551,7 +2559,7 @@ bt_stream_class_borrow_default_clock_class_const( */ extern const bt_clock_class * bt_message_discarded_events_borrow_stream_class_default_clock_class_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2578,7 +2586,7 @@ property. message. */ extern void bt_message_discarded_events_set_count(bt_message *message, - uint64_t count); + uint64_t count) __BT_NOEXCEPT; /*! @brief @@ -2609,7 +2617,7 @@ property. Sets the number of discarded events of a discarded events message. */ extern bt_property_availability bt_message_discarded_events_get_count( - const bt_message *message, uint64_t *count); + const bt_message *message, uint64_t *count) __BT_NOEXCEPT; /*! @} */ @@ -2678,7 +2686,7 @@ property values: */ extern bt_message *bt_message_discarded_packets_create( bt_self_message_iterator *self_message_iterator, - const bt_stream *stream); + const bt_stream *stream) __BT_NOEXCEPT; /*! @brief @@ -2750,7 +2758,7 @@ property values: extern bt_message *bt_message_discarded_packets_create_with_default_clock_snapshots( bt_self_message_iterator *self_message_iterator, const bt_stream *stream, uint64_t beginning_clock_snapshot_value, - uint64_t end_clock_snapshot_value); + uint64_t end_clock_snapshot_value) __BT_NOEXCEPT; /*! @brief @@ -2775,7 +2783,7 @@ See the \ref api-msg-disc-ev-prop-stream "stream" property. \c const version of this function. */ extern bt_stream *bt_message_discarded_packets_borrow_stream( - bt_message *message); + bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2785,7 +2793,8 @@ extern bt_stream *bt_message_discarded_packets_borrow_stream( See bt_message_discarded_packets_borrow_stream(). */ extern const bt_stream * -bt_message_discarded_packets_borrow_stream_const(const bt_message *message); +bt_message_discarded_packets_borrow_stream_const(const bt_message *message) + __BT_NOEXCEPT; /*! @brief @@ -2812,7 +2821,7 @@ property. */ extern const bt_clock_snapshot * bt_message_discarded_packets_borrow_beginning_default_clock_snapshot_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2839,7 +2848,7 @@ property. */ extern const bt_clock_snapshot * bt_message_discarded_packets_borrow_end_default_clock_snapshot_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2871,7 +2880,7 @@ bt_stream_class_borrow_default_clock_class_const( */ extern const bt_clock_class * bt_message_discarded_packets_borrow_stream_class_default_clock_class_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -2898,7 +2907,7 @@ property. message. */ extern void bt_message_discarded_packets_set_count(bt_message *message, - uint64_t count); + uint64_t count) __BT_NOEXCEPT; /*! @brief @@ -2929,7 +2938,7 @@ property. Sets the number of discarded packets of a discarded packets message. */ extern bt_property_availability bt_message_discarded_packets_get_count( - const bt_message *message, uint64_t *count); + const bt_message *message, uint64_t *count) __BT_NOEXCEPT; /*! @} */ @@ -2981,7 +2990,7 @@ extern bt_message *bt_message_message_iterator_inactivity_create( bt_self_message_iterator *self_message_iterator, const bt_clock_class *clock_class, - uint64_t clock_snapshot_value); + uint64_t clock_snapshot_value) __BT_NOEXCEPT; /*! @brief @@ -3001,7 +3010,7 @@ See the \ref api-msg-inac-prop-cs "clock snapshot" property. */ extern const bt_clock_snapshot * bt_message_message_iterator_inactivity_borrow_clock_snapshot_const( - const bt_message *message); + const bt_message *message) __BT_NOEXCEPT; /*! @} */ @@ -3025,7 +3034,7 @@ bt_message_message_iterator_inactivity_borrow_clock_snapshot_const( @sa bt_message_put_ref() — Decrements the reference count of a message. */ -extern void bt_message_get_ref(const bt_message *message); +extern void bt_message_get_ref(const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -3042,7 +3051,7 @@ extern void bt_message_get_ref(const bt_message *message); @sa bt_message_get_ref() — Increments the reference count of a message. */ -extern void bt_message_put_ref(const bt_message *message); +extern void bt_message_put_ref(const bt_message *message) __BT_NOEXCEPT; /*! @brief @@ -3188,7 +3197,8 @@ component descriptors of \bt_p{component_descriptors}, it returns extern bt_get_greatest_operative_mip_version_status bt_get_greatest_operative_mip_version( const bt_component_descriptor_set *component_descriptors, - bt_logging_level logging_level, uint64_t *mip_version); + bt_logging_level logging_level, uint64_t *mip_version) + __BT_NOEXCEPT; /*! @brief @@ -3201,7 +3211,7 @@ As of \bt_name_version_min_maj, this function returns @returns Maximal available MIP version (\bt_max_mip_version). */ -extern uint64_t bt_get_maximal_mip_version(void); +extern uint64_t bt_get_maximal_mip_version(void) __BT_NOEXCEPT; /*! @} */ diff --git a/include/babeltrace2/graph/port.h b/include/babeltrace2/graph/port.h index aa3d7691..b25395ee 100644 --- a/include/babeltrace2/graph/port.h +++ b/include/babeltrace2/graph/port.h @@ -193,7 +193,7 @@ typedef enum bt_port_type { @sa bt_port_is_output() — Returns whether or not a port is an \bt_oport. */ -extern bt_port_type bt_port_get_type(const bt_port *port); +extern bt_port_type bt_port_get_type(const bt_port *port) __BT_NOEXCEPT; /*! @brief @@ -211,7 +211,7 @@ extern bt_port_type bt_port_get_type(const bt_port *port); Returns the type enumerator of a port. */ static inline -bt_bool bt_port_is_input(const bt_port *port) +bt_bool bt_port_is_input(const bt_port *port) __BT_NOEXCEPT { return bt_port_get_type(port) == BT_PORT_TYPE_INPUT; } @@ -232,7 +232,7 @@ bt_bool bt_port_is_input(const bt_port *port) Returns the type enumerator of a port. */ static inline -bt_bool bt_port_is_output(const bt_port *port) +bt_bool bt_port_is_output(const bt_port *port) __BT_NOEXCEPT { return bt_port_get_type(port) == BT_PORT_TYPE_OUTPUT; } @@ -260,7 +260,7 @@ This function returns \c NULL if \bt_p{port} is unconnected @bt_pre_not_null{port} */ extern const bt_connection *bt_port_borrow_connection_const( - const bt_port *port); + const bt_port *port) __BT_NOEXCEPT; /*! @} */ @@ -282,7 +282,7 @@ extern const bt_connection *bt_port_borrow_connection_const( @bt_pre_not_null{port} */ extern const bt_component *bt_port_borrow_component_const( - const bt_port *port); + const bt_port *port) __BT_NOEXCEPT; /*! @} */ @@ -309,7 +309,7 @@ See the \ref api-port-prop-name "name" property. @bt_pre_not_null{port} */ -extern const char *bt_port_get_name(const bt_port *port); +extern const char *bt_port_get_name(const bt_port *port) __BT_NOEXCEPT; /*! @brief @@ -325,7 +325,7 @@ See the \ref api-port-prop-is-connected "is connected?" property. @bt_pre_not_null{port} */ -extern bt_bool bt_port_is_connected(const bt_port *port); +extern bt_bool bt_port_is_connected(const bt_port *port) __BT_NOEXCEPT; /*! @} */ @@ -349,7 +349,7 @@ extern bt_bool bt_port_is_connected(const bt_port *port); @sa bt_port_put_ref() — Decrements the reference count of a port. */ -extern void bt_port_get_ref(const bt_port *port); +extern void bt_port_get_ref(const bt_port *port) __BT_NOEXCEPT; /*! @brief @@ -366,7 +366,7 @@ extern void bt_port_get_ref(const bt_port *port); @sa bt_port_get_ref() — Increments the reference count of a port. */ -extern void bt_port_put_ref(const bt_port *port); +extern void bt_port_put_ref(const bt_port *port) __BT_NOEXCEPT; /*! @brief @@ -443,7 +443,8 @@ existing \bt_p{_dst} reference. \bt_p{port} as a common port. */ static inline -const bt_port *bt_port_input_as_port_const(const bt_port_input *port) +const bt_port *bt_port_input_as_port_const( + const bt_port_input *port) __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_port, port); } @@ -463,7 +464,7 @@ const bt_port *bt_port_input_as_port_const(const bt_port_input *port) @sa bt_port_input_put_ref() — Decrements the reference count of an input port. */ -extern void bt_port_input_get_ref(const bt_port_input *port); +extern void bt_port_input_get_ref(const bt_port_input *port) __BT_NOEXCEPT; /*! @brief @@ -480,7 +481,7 @@ extern void bt_port_input_get_ref(const bt_port_input *port); @sa bt_port_input_get_ref() — Increments the reference count of an input port. */ -extern void bt_port_input_put_ref(const bt_port_input *port); +extern void bt_port_input_put_ref(const bt_port_input *port) __BT_NOEXCEPT; /*! @brief @@ -557,7 +558,8 @@ existing \bt_p{_dst} reference. \bt_p{port} as a common port. */ static inline -const bt_port *bt_port_output_as_port_const(const bt_port_output *port) +const bt_port *bt_port_output_as_port_const( + const bt_port_output *port) __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_port, port); } @@ -577,7 +579,7 @@ const bt_port *bt_port_output_as_port_const(const bt_port_output *port) @sa bt_port_output_put_ref() — Decrements the reference count of a \bt_oport. */ -extern void bt_port_output_get_ref(const bt_port_output *port); +extern void bt_port_output_get_ref(const bt_port_output *port) __BT_NOEXCEPT; /*! @brief @@ -594,7 +596,7 @@ extern void bt_port_output_get_ref(const bt_port_output *port); @sa bt_port_output_get_ref() — Increments the reference count of a \bt_oport. */ -extern void bt_port_output_put_ref(const bt_port_output *port); +extern void bt_port_output_put_ref(const bt_port_output *port) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/graph/private-query-executor.h b/include/babeltrace2/graph/private-query-executor.h index 756f5eec..81a0daeb 100644 --- a/include/babeltrace2/graph/private-query-executor.h +++ b/include/babeltrace2/graph/private-query-executor.h @@ -79,7 +79,7 @@ bt_private_query_executor_as_query_executor_const() function to static inline const bt_query_executor * bt_private_query_executor_as_query_executor_const( - bt_private_query_executor *query_executor) + bt_private_query_executor *query_executor) __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_query_executor, query_executor); } diff --git a/include/babeltrace2/graph/query-executor.h b/include/babeltrace2/graph/query-executor.h index 89432934..0d4757a5 100644 --- a/include/babeltrace2/graph/query-executor.h +++ b/include/babeltrace2/graph/query-executor.h @@ -145,7 +145,8 @@ A query executor has the following property: extern bt_query_executor *bt_query_executor_create( const bt_component_class *component_class, - const char *object_name, const bt_value *params); + const char *object_name, const bt_value *params) + __BT_NOEXCEPT; /*! @brief @@ -198,7 +199,7 @@ extern bt_query_executor *bt_query_executor_create_with_method_data( const bt_component_class *component_class, const char *object_name, const bt_value *params, - void *method_data); + void *method_data) __BT_NOEXCEPT; /*! @} */ @@ -287,7 +288,8 @@ bt_query_executor_create_with_method_data(). */ extern bt_query_executor_query_status bt_query_executor_query( - bt_query_executor *query_executor, const bt_value **result); + bt_query_executor *query_executor, const bt_value **result) + __BT_NOEXCEPT; /*! @} */ @@ -331,7 +333,7 @@ See the \ref api-qexec-prop-log-lvl "logging level" property. */ extern bt_query_executor_set_logging_level_status bt_query_executor_set_logging_level(bt_query_executor *query_executor, - bt_logging_level logging_level); + bt_logging_level logging_level) __BT_NOEXCEPT; /*! @brief @@ -352,7 +354,7 @@ See the \ref api-qexec-prop-log-lvl "logging level" property. Sets the logging level of a query executor. */ extern bt_logging_level bt_query_executor_get_logging_level( - const bt_query_executor *query_executor); + const bt_query_executor *query_executor) __BT_NOEXCEPT; /*! @} */ @@ -420,7 +422,7 @@ is set) with bt_query_executor_is_interrupted(). */ extern bt_query_executor_add_interrupter_status bt_query_executor_add_interrupter(bt_query_executor *query_executor, - const bt_interrupter *interrupter); + const bt_interrupter *interrupter) __BT_NOEXCEPT; /*! @brief @@ -445,7 +447,7 @@ bt_query_executor_add_interrupter(bt_query_executor *query_executor, Adds an interrupter to a query executor. */ extern bt_interrupter *bt_query_executor_borrow_default_interrupter( - bt_query_executor *query_executor); + bt_query_executor *query_executor) __BT_NOEXCEPT; /*! @brief @@ -463,7 +465,7 @@ extern bt_interrupter *bt_query_executor_borrow_default_interrupter( @bt_pre_not_null{query_executor} */ extern bt_bool bt_query_executor_is_interrupted( - const bt_query_executor *query_executor); + const bt_query_executor *query_executor) __BT_NOEXCEPT; /*! @} */ @@ -487,7 +489,8 @@ extern bt_bool bt_query_executor_is_interrupted( @sa bt_query_executor_put_ref() — Decrements the reference count of a query executor. */ -extern void bt_query_executor_get_ref(const bt_query_executor *query_executor); +extern void bt_query_executor_get_ref(const bt_query_executor *query_executor) + __BT_NOEXCEPT; /*! @brief @@ -504,7 +507,8 @@ extern void bt_query_executor_get_ref(const bt_query_executor *query_executor); @sa bt_query_executor_get_ref() — Increments the reference count of a query executor. */ -extern void bt_query_executor_put_ref(const bt_query_executor *query_executor); +extern void bt_query_executor_put_ref(const bt_query_executor *query_executor) + __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/graph/self-component-class.h b/include/babeltrace2/graph/self-component-class.h index 994367f4..366f7146 100644 --- a/include/babeltrace2/graph/self-component-class.h +++ b/include/babeltrace2/graph/self-component-class.h @@ -88,7 +88,7 @@ public #bt_component_class, #bt_component_class_source, */ static inline const bt_component_class *bt_self_component_class_as_component_class( - bt_self_component_class *self_component_class) + bt_self_component_class *self_component_class) __BT_NOEXCEPT { return __BT_UPCAST(bt_component_class, self_component_class); } @@ -113,6 +113,7 @@ static inline const bt_component_class_source * bt_self_component_class_source_as_component_class_source( bt_self_component_class_source *self_component_class) + __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_component_class_source, self_component_class); @@ -138,6 +139,7 @@ static inline const bt_component_class_filter * bt_self_component_class_filter_as_component_class_filter( bt_self_component_class_filter *self_component_class) + __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_component_class_filter, self_component_class); @@ -163,6 +165,7 @@ static inline const bt_component_class_sink * bt_self_component_class_sink_as_component_class_sink( bt_self_component_class_sink *self_component_class) + __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_component_class_sink, self_component_class); } @@ -194,6 +197,7 @@ static inline bt_self_component_class* bt_self_component_class_source_as_self_component_class( bt_self_component_class_source *self_component_class) + __BT_NOEXCEPT { return __BT_UPCAST(bt_self_component_class, self_component_class); } @@ -218,6 +222,7 @@ static inline bt_self_component_class* bt_self_component_class_filter_as_self_component_class( bt_self_component_class_filter *self_component_class) + __BT_NOEXCEPT { return __BT_UPCAST(bt_self_component_class, self_component_class); } @@ -242,6 +247,7 @@ static inline bt_self_component_class* bt_self_component_class_sink_as_self_component_class( bt_self_component_class_sink *self_component_class) + __BT_NOEXCEPT { return __BT_UPCAST(bt_self_component_class, self_component_class); } diff --git a/include/babeltrace2/graph/self-component-port.h b/include/babeltrace2/graph/self-component-port.h index cb13127c..5cb500b2 100644 --- a/include/babeltrace2/graph/self-component-port.h +++ b/include/babeltrace2/graph/self-component-port.h @@ -86,7 +86,7 @@ functions. @bt_pre_not_null{self_component_port} */ extern bt_self_component *bt_self_component_port_borrow_component( - bt_self_component_port *self_component_port); + bt_self_component_port *self_component_port) __BT_NOEXCEPT; /*! @} */ @@ -114,7 +114,8 @@ bt_self_component_sink_add_input_port(). @bt_pre_not_null{self_component_port} */ extern void *bt_self_component_port_get_data( - const bt_self_component_port *self_component_port); + const bt_self_component_port *self_component_port) + __BT_NOEXCEPT; /*! @} */ @@ -140,7 +141,7 @@ extern void *bt_self_component_port_get_data( */ static inline const bt_port *bt_self_component_port_as_port( - bt_self_component_port *self_component_port) + bt_self_component_port *self_component_port) __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_port, self_component_port); } @@ -163,6 +164,7 @@ const bt_port *bt_self_component_port_as_port( static inline const bt_port_input *bt_self_component_port_input_as_port_input( const bt_self_component_port_input *self_component_port) + __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_port_input, self_component_port); } @@ -185,6 +187,7 @@ const bt_port_input *bt_self_component_port_input_as_port_input( static inline const bt_port_output *bt_self_component_port_output_as_port_output( bt_self_component_port_output *self_component_port) + __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_port_output, self_component_port); } @@ -216,6 +219,7 @@ static inline bt_self_component_port * bt_self_component_port_input_as_self_component_port( bt_self_component_port_input *self_component_port) + __BT_NOEXCEPT { return __BT_UPCAST(bt_self_component_port, self_component_port); } @@ -240,6 +244,7 @@ static inline bt_self_component_port * bt_self_component_port_output_as_self_component_port( bt_self_component_port_output *self_component_port) + __BT_NOEXCEPT { return __BT_UPCAST(bt_self_component_port, self_component_port); } diff --git a/include/babeltrace2/graph/self-component.h b/include/babeltrace2/graph/self-component.h index c6276116..77e299af 100644 --- a/include/babeltrace2/graph/self-component.h +++ b/include/babeltrace2/graph/self-component.h @@ -186,7 +186,8 @@ extern bt_self_component_add_port_status bt_self_component_source_add_output_port( bt_self_component_source *self_component, const char *name, void *user_data, - bt_self_component_port_output **self_component_port); + bt_self_component_port_output **self_component_port) + __BT_NOEXCEPT; /*! @brief @@ -230,7 +231,8 @@ extern bt_self_component_add_port_status bt_self_component_filter_add_input_port( bt_self_component_filter *self_component, const char *name, void *user_data, - bt_self_component_port_input **self_component_port); + bt_self_component_port_input **self_component_port) + __BT_NOEXCEPT; /*! @brief @@ -274,7 +276,8 @@ extern bt_self_component_add_port_status bt_self_component_filter_add_output_port( bt_self_component_filter *self_component, const char *name, void *user_data, - bt_self_component_port_output **self_component_port); + bt_self_component_port_output **self_component_port) + __BT_NOEXCEPT; /*! @brief @@ -319,7 +322,8 @@ extern bt_self_component_add_port_status bt_self_component_sink_add_input_port( bt_self_component_sink *self_component, const char *name, void *user_data, - bt_self_component_port_input **self_component_port); + bt_self_component_port_input **self_component_port) + __BT_NOEXCEPT; /*! @} */ @@ -359,7 +363,7 @@ bt_self_component_sink_add_input_port( extern bt_self_component_port_output * bt_self_component_source_borrow_output_port_by_index( bt_self_component_source *self_component, - uint64_t index); + uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -392,7 +396,7 @@ bt_self_component_source_borrow_output_port_by_index( extern bt_self_component_port_input * bt_self_component_filter_borrow_input_port_by_index( bt_self_component_filter *self_component, - uint64_t index); + uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -425,7 +429,7 @@ bt_self_component_filter_borrow_input_port_by_index( extern bt_self_component_port_output * bt_self_component_filter_borrow_output_port_by_index( bt_self_component_filter *self_component, - uint64_t index); + uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -457,7 +461,8 @@ bt_self_component_filter_borrow_output_port_by_index( */ extern bt_self_component_port_input * bt_self_component_sink_borrow_input_port_by_index( - bt_self_component_sink *self_component, uint64_t index); + bt_self_component_sink *self_component, uint64_t index) + __BT_NOEXCEPT; /*! @brief @@ -487,7 +492,7 @@ function returns \c NULL. extern bt_self_component_port_output * bt_self_component_source_borrow_output_port_by_name( bt_self_component_source *self_component, - const char *name); + const char *name) __BT_NOEXCEPT; /*! @brief @@ -517,7 +522,7 @@ function returns \c NULL. extern bt_self_component_port_input * bt_self_component_filter_borrow_input_port_by_name( bt_self_component_filter *self_component, - const char *name); + const char *name) __BT_NOEXCEPT; /*! @brief @@ -547,7 +552,7 @@ function returns \c NULL. extern bt_self_component_port_output * bt_self_component_filter_borrow_output_port_by_name( bt_self_component_filter *self_component, - const char *name); + const char *name) __BT_NOEXCEPT; /*! @brief @@ -577,7 +582,7 @@ function returns \c NULL. extern bt_self_component_port_input * bt_self_component_sink_borrow_input_port_by_name( bt_self_component_sink *self_component, - const char *name); + const char *name) __BT_NOEXCEPT; /*! @} */ @@ -602,7 +607,8 @@ bt_self_component_sink_borrow_input_port_by_name( Returns the user data of a component. */ extern void bt_self_component_set_data( - bt_self_component *self_component, void *user_data); + bt_self_component *self_component, void *user_data) + __BT_NOEXCEPT; /*! @brief @@ -620,7 +626,7 @@ extern void bt_self_component_set_data( Sets the user data of a component. */ extern void *bt_self_component_get_data( - const bt_self_component *self_component); + const bt_self_component *self_component) __BT_NOEXCEPT; /*! @} */ @@ -649,7 +655,7 @@ extern void *bt_self_component_get_data( */ extern uint64_t bt_self_component_get_graph_mip_version( - bt_self_component *self_component); + bt_self_component *self_component) __BT_NOEXCEPT; /*! @} */ @@ -679,7 +685,7 @@ uint64_t bt_self_component_get_graph_mip_version( Adds an interrupter to a graph. */ extern bt_bool bt_self_component_sink_is_interrupted( - const bt_self_component_sink *self_component); + const bt_self_component_sink *self_component) __BT_NOEXCEPT; /*! @} */ @@ -705,7 +711,7 @@ extern bt_bool bt_self_component_sink_is_interrupted( */ static inline const bt_component *bt_self_component_as_component( - bt_self_component *self_component) + bt_self_component *self_component) __BT_NOEXCEPT { return __BT_UPCAST(bt_component, self_component); } @@ -729,7 +735,7 @@ const bt_component *bt_self_component_as_component( static inline const bt_component_source * bt_self_component_source_as_component_source( - bt_self_component_source *self_component) + bt_self_component_source *self_component) __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_component_source, self_component); } @@ -753,7 +759,7 @@ bt_self_component_source_as_component_source( static inline const bt_component_filter * bt_self_component_filter_as_component_filter( - bt_self_component_filter *self_component) + bt_self_component_filter *self_component) __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_component_filter, self_component); } @@ -777,7 +783,7 @@ bt_self_component_filter_as_component_filter( static inline const bt_component_sink * bt_self_component_sink_as_component_sink( - bt_self_component_sink *self_component) + bt_self_component_sink *self_component) __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_component_sink, self_component); } @@ -807,7 +813,7 @@ bt_self_component_sink_as_component_sink( */ static inline bt_self_component *bt_self_component_source_as_self_component( - bt_self_component_source *self_component) + bt_self_component_source *self_component) __BT_NOEXCEPT { return __BT_UPCAST(bt_self_component, self_component); } @@ -830,7 +836,7 @@ bt_self_component *bt_self_component_source_as_self_component( */ static inline bt_self_component *bt_self_component_filter_as_self_component( - bt_self_component_filter *self_component) + bt_self_component_filter *self_component) __BT_NOEXCEPT { return __BT_UPCAST(bt_self_component, self_component); } @@ -853,7 +859,7 @@ bt_self_component *bt_self_component_filter_as_self_component( */ static inline bt_self_component *bt_self_component_sink_as_self_component( - bt_self_component_sink *self_component) + bt_self_component_sink *self_component) __BT_NOEXCEPT { return __BT_UPCAST(bt_self_component, self_component); } diff --git a/include/babeltrace2/graph/self-message-iterator.h b/include/babeltrace2/graph/self-message-iterator.h index 43d9464e..556a172f 100644 --- a/include/babeltrace2/graph/self-message-iterator.h +++ b/include/babeltrace2/graph/self-message-iterator.h @@ -85,7 +85,7 @@ bt_self_message_iterator_configuration_set_can_seek_forward(). */ extern bt_self_component * bt_self_message_iterator_borrow_component( - bt_self_message_iterator *self_message_iterator); + bt_self_message_iterator *self_message_iterator) __BT_NOEXCEPT; /*! @} */ @@ -109,7 +109,8 @@ bt_self_message_iterator_borrow_component( */ extern bt_self_component_port_output * bt_self_message_iterator_borrow_port( - bt_self_message_iterator *self_message_iterator); + bt_self_message_iterator *self_message_iterator) + __BT_NOEXCEPT; /*! @} */ @@ -135,7 +136,7 @@ bt_self_message_iterator_borrow_port( */ extern void bt_self_message_iterator_set_data( bt_self_message_iterator *self_message_iterator, - void *user_data); + void *user_data) __BT_NOEXCEPT; /*! @brief @@ -155,7 +156,8 @@ extern void bt_self_message_iterator_set_data( */ extern void *bt_self_message_iterator_get_data( - const bt_self_message_iterator *self_message_iterator); + const bt_self_message_iterator *self_message_iterator) + __BT_NOEXCEPT; /*! @} */ @@ -185,7 +187,8 @@ void *bt_self_message_iterator_get_data( Adds an interrupter to a graph. */ extern bt_bool bt_self_message_iterator_is_interrupted( - const bt_self_message_iterator *self_message_iterator); + const bt_self_message_iterator *self_message_iterator) + __BT_NOEXCEPT; /*! @} */ @@ -221,7 +224,7 @@ message sequence have some \bt_cs. */ extern void bt_self_message_iterator_configuration_set_can_seek_forward( bt_self_message_iterator_configuration *configuration, - bt_bool can_seek_forward); + bt_bool can_seek_forward) __BT_NOEXCEPT; /*! @} */ diff --git a/include/babeltrace2/integer-range-set.h b/include/babeltrace2/integer-range-set.h index f4984b2e..d3aff20e 100644 --- a/include/babeltrace2/integer-range-set.h +++ b/include/babeltrace2/integer-range-set.h @@ -149,7 +149,7 @@ The returned lower value is included in \bt_p{int_range}. @bt_pre_is_bool_val{int_range} */ extern uint64_t bt_integer_range_unsigned_get_lower( - const bt_integer_range_unsigned *int_range); + const bt_integer_range_unsigned *int_range) __BT_NOEXCEPT; /*! @brief @@ -168,7 +168,7 @@ The returned upper value is included in \bt_p{int_range}. @bt_pre_is_bool_val{int_range} */ extern uint64_t bt_integer_range_unsigned_get_upper( - const bt_integer_range_unsigned *int_range); + const bt_integer_range_unsigned *int_range) __BT_NOEXCEPT; /*! @brief @@ -192,7 +192,7 @@ lower and upper values. */ extern bt_bool bt_integer_range_unsigned_is_equal( const bt_integer_range_unsigned *a_int_range, - const bt_integer_range_unsigned *b_int_range); + const bt_integer_range_unsigned *b_int_range) __BT_NOEXCEPT; /*! @} */ @@ -218,7 +218,7 @@ The returned lower value is included in \bt_p{int_range}. @bt_pre_is_bool_val{int_range} */ extern int64_t bt_integer_range_signed_get_lower( - const bt_integer_range_signed *int_range); + const bt_integer_range_signed *int_range) __BT_NOEXCEPT; /*! @brief @@ -237,7 +237,7 @@ The returned upper value is included in \bt_p{int_range}. @bt_pre_is_bool_val{int_range} */ extern int64_t bt_integer_range_signed_get_upper( - const bt_integer_range_signed *int_range); + const bt_integer_range_signed *int_range) __BT_NOEXCEPT; /*! @brief @@ -261,7 +261,7 @@ lower and upper values. */ extern bt_bool bt_integer_range_signed_is_equal( const bt_integer_range_signed *a_int_range, - const bt_integer_range_signed *b_int_range); + const bt_integer_range_signed *b_int_range) __BT_NOEXCEPT; /*! @} */ @@ -311,7 +311,7 @@ typedef enum bt_integer_range_set_add_range_status { @bt_pre_not_null{int_range_set} */ extern uint64_t bt_integer_range_set_get_range_count( - const bt_integer_range_set *int_range_set); + const bt_integer_range_set *int_range_set) __BT_NOEXCEPT; /*! @} */ @@ -327,7 +327,8 @@ extern uint64_t bt_integer_range_set_get_range_count( @returns New unsigned integer range set, or \c NULL on memory error. */ -extern bt_integer_range_set_unsigned *bt_integer_range_set_unsigned_create(void); +extern bt_integer_range_set_unsigned *bt_integer_range_set_unsigned_create( + void) __BT_NOEXCEPT; /*! @brief @@ -362,7 +363,7 @@ integer range to add to \bt_p{int_range_set}. extern bt_integer_range_set_add_range_status bt_integer_range_set_unsigned_add_range( bt_integer_range_set_unsigned *int_range_set, - uint64_t lower, uint64_t upper); + uint64_t lower, uint64_t upper) __BT_NOEXCEPT; /*! @brief @@ -394,7 +395,7 @@ bt_integer_range_set_unsigned_add_range( extern const bt_integer_range_unsigned * bt_integer_range_set_unsigned_borrow_range_by_index_const( const bt_integer_range_set_unsigned *int_range_set, - uint64_t index); + uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -420,7 +421,8 @@ is \em not equal to an unsigned integer range containing [2, 15]. */ extern bt_bool bt_integer_range_set_unsigned_is_equal( const bt_integer_range_set_unsigned *int_range_set_a, - const bt_integer_range_set_unsigned *int_range_set_b); + const bt_integer_range_set_unsigned *int_range_set_b) + __BT_NOEXCEPT; /*! @brief @@ -440,6 +442,7 @@ extern bt_bool bt_integer_range_set_unsigned_is_equal( static inline const bt_integer_range_set *bt_integer_range_set_unsigned_as_range_set_const( const bt_integer_range_set_unsigned *int_range_set) + __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_integer_range_set, int_range_set); } @@ -461,7 +464,8 @@ const bt_integer_range_set *bt_integer_range_set_unsigned_as_range_set_const( Decrements the reference count of an unsigned integer range set. */ extern void bt_integer_range_set_unsigned_get_ref( - const bt_integer_range_set_unsigned *int_range_set); + const bt_integer_range_set_unsigned *int_range_set) + __BT_NOEXCEPT; /*! @brief @@ -480,7 +484,8 @@ extern void bt_integer_range_set_unsigned_get_ref( Increments the reference count of an unsigned integer range set. */ extern void bt_integer_range_set_unsigned_put_ref( - const bt_integer_range_set_unsigned *int_range_set); + const bt_integer_range_set_unsigned *int_range_set) + __BT_NOEXCEPT; /*! @brief @@ -551,7 +556,8 @@ the existing \bt_p{_dst} reference. @returns New signed integer range set, or \c NULL on memory error. */ -extern bt_integer_range_set_signed *bt_integer_range_set_signed_create(void); +extern bt_integer_range_set_signed *bt_integer_range_set_signed_create( + void) __BT_NOEXCEPT; /*! @brief @@ -586,7 +592,7 @@ integer range to add to \bt_p{int_range_set}. extern bt_integer_range_set_add_range_status bt_integer_range_set_signed_add_range( bt_integer_range_set_signed *int_range_set, - int64_t lower, int64_t upper); + int64_t lower, int64_t upper) __BT_NOEXCEPT; /*! @brief @@ -617,7 +623,8 @@ bt_integer_range_set_signed_add_range( */ extern const bt_integer_range_signed * bt_integer_range_set_signed_borrow_range_by_index_const( - const bt_integer_range_set_signed *int_range_set, uint64_t index); + const bt_integer_range_set_signed *int_range_set, + uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -643,7 +650,8 @@ is \em not equal to a signed integer range containing [−57, 42]. */ extern bt_bool bt_integer_range_set_signed_is_equal( const bt_integer_range_set_signed *int_range_set_a, - const bt_integer_range_set_signed *int_range_set_b); + const bt_integer_range_set_signed *int_range_set_b) + __BT_NOEXCEPT; /*! @brief @@ -663,6 +671,7 @@ extern bt_bool bt_integer_range_set_signed_is_equal( static inline const bt_integer_range_set *bt_integer_range_set_signed_as_range_set_const( const bt_integer_range_set_signed *int_range_set) + __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_integer_range_set, int_range_set); } @@ -684,7 +693,7 @@ const bt_integer_range_set *bt_integer_range_set_signed_as_range_set_const( Decrements the reference count of a signed integer range set. */ extern void bt_integer_range_set_signed_get_ref( - const bt_integer_range_set_signed *int_range_set); + const bt_integer_range_set_signed *int_range_set) __BT_NOEXCEPT; /*! @brief @@ -703,7 +712,7 @@ extern void bt_integer_range_set_signed_get_ref( Increments the reference count of a signed integer range set. */ extern void bt_integer_range_set_signed_put_ref( - const bt_integer_range_set_signed *int_range_set); + const bt_integer_range_set_signed *int_range_set) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/logging.h b/include/babeltrace2/logging.h index f8ac11fb..14660186 100644 --- a/include/babeltrace2/logging.h +++ b/include/babeltrace2/logging.h @@ -189,7 +189,8 @@ individual components and query operations. @sa bt_logging_get_global_level() — Returns the current library's global logging level. */ -extern void bt_logging_set_global_level(bt_logging_level logging_level); +extern void bt_logging_set_global_level(bt_logging_level logging_level) + __BT_NOEXCEPT; /*! @brief @@ -201,7 +202,7 @@ extern void bt_logging_set_global_level(bt_logging_level logging_level); @sa bt_logging_set_global_level() — Sets the current library's global logging level. */ -extern bt_logging_level bt_logging_get_global_level(void); +extern bt_logging_level bt_logging_get_global_level(void) __BT_NOEXCEPT; /*! @brief @@ -220,7 +221,7 @@ are not built. @sa bt_logging_get_global_level() — Returns the current library's global logging level. */ -extern bt_logging_level bt_logging_get_minimal_level(void); +extern bt_logging_level bt_logging_get_minimal_level(void) __BT_NOEXCEPT; /*! @} */ diff --git a/include/babeltrace2/plugin/plugin-loading.h b/include/babeltrace2/plugin/plugin-loading.h index a2615da6..9bb598a0 100644 --- a/include/babeltrace2/plugin/plugin-loading.h +++ b/include/babeltrace2/plugin/plugin-loading.h @@ -377,7 +377,8 @@ If this function doesn't find any plugin, it returns extern bt_plugin_find_status bt_plugin_find(const char *plugin_name, bt_bool find_in_std_env_var, bt_bool find_in_user_dir, bt_bool find_in_sys_dir, bt_bool find_in_static, - bt_bool fail_on_load_error, const bt_plugin **plugin); + bt_bool fail_on_load_error, const bt_plugin **plugin) + __BT_NOEXCEPT; /*! @brief @@ -501,7 +502,7 @@ If this function doesn't find any plugin, it returns bt_plugin_find_all_status bt_plugin_find_all(bt_bool find_in_std_env_var, bt_bool find_in_user_dir, bt_bool find_in_sys_dir, bt_bool find_in_static, bt_bool fail_on_load_error, - const bt_plugin_set **plugins); + const bt_plugin_set **plugins) __BT_NOEXCEPT; /*! @brief @@ -588,7 +589,7 @@ If this function doesn't find any plugin, it returns */ extern bt_plugin_find_all_from_file_status bt_plugin_find_all_from_file( const char *path, bt_bool fail_on_load_error, - const bt_plugin_set **plugins); + const bt_plugin_set **plugins) __BT_NOEXCEPT; /*! @brief @@ -683,7 +684,7 @@ If this function doesn't find any plugin, it returns */ extern bt_plugin_find_all_from_dir_status bt_plugin_find_all_from_dir( const char *path, bt_bool recurse, bt_bool fail_on_load_error, - const bt_plugin_set **plugins); + const bt_plugin_set **plugins) __BT_NOEXCEPT; /*! @brief @@ -759,7 +760,8 @@ If this function doesn't find any plugin, it returns @bt_pre_not_null{plugins} */ extern bt_plugin_find_all_from_static_status bt_plugin_find_all_from_static( - bt_bool fail_on_load_error, const bt_plugin_set **plugins); + bt_bool fail_on_load_error, const bt_plugin_set **plugins) + __BT_NOEXCEPT; /*! @} */ @@ -786,7 +788,7 @@ See the \ref api-plugin-prop-name "name" property. @bt_pre_not_null{plugin} */ -extern const char *bt_plugin_get_name(const bt_plugin *plugin); +extern const char *bt_plugin_get_name(const bt_plugin *plugin) __BT_NOEXCEPT; /*! @brief @@ -806,7 +808,8 @@ See the \ref api-plugin-prop-descr "description" property. @bt_pre_not_null{plugin} */ -extern const char *bt_plugin_get_description(const bt_plugin *plugin); +extern const char *bt_plugin_get_description(const bt_plugin *plugin) + __BT_NOEXCEPT; /*! @brief @@ -826,7 +829,7 @@ See the \ref api-plugin-prop-author "author name(s)" property. @bt_pre_not_null{plugin} */ -extern const char *bt_plugin_get_author(const bt_plugin *plugin); +extern const char *bt_plugin_get_author(const bt_plugin *plugin) __BT_NOEXCEPT; /*! @brief @@ -847,7 +850,7 @@ See the \ref api-plugin-prop-license "license" property. @bt_pre_not_null{plugin} */ -extern const char *bt_plugin_get_license(const bt_plugin *plugin); +extern const char *bt_plugin_get_license(const bt_plugin *plugin) __BT_NOEXCEPT; /*! @brief @@ -872,7 +875,7 @@ because a static plugin has no path property. @bt_pre_not_null{plugin} */ -extern const char *bt_plugin_get_path(const bt_plugin *plugin); +extern const char *bt_plugin_get_path(const bt_plugin *plugin) __BT_NOEXCEPT; /*! @brief @@ -915,7 +918,8 @@ See the \ref api-plugin-prop-version "version" property. */ extern bt_property_availability bt_plugin_get_version( const bt_plugin *plugin, unsigned int *major, - unsigned int *minor, unsigned int *patch, const char **extra); + unsigned int *minor, unsigned int *patch, const char **extra) + __BT_NOEXCEPT; /*! @} */ @@ -939,7 +943,7 @@ extern bt_property_availability bt_plugin_get_version( @bt_pre_not_null{plugin} */ extern uint64_t bt_plugin_get_source_component_class_count( - const bt_plugin *plugin); + const bt_plugin *plugin) __BT_NOEXCEPT; /*! @brief @@ -956,7 +960,7 @@ extern uint64_t bt_plugin_get_source_component_class_count( @bt_pre_not_null{plugin} */ extern uint64_t bt_plugin_get_filter_component_class_count( - const bt_plugin *plugin); + const bt_plugin *plugin) __BT_NOEXCEPT; /*! @brief @@ -973,7 +977,7 @@ extern uint64_t bt_plugin_get_filter_component_class_count( @bt_pre_not_null{plugin} */ extern uint64_t bt_plugin_get_sink_component_class_count( - const bt_plugin *plugin); + const bt_plugin *plugin) __BT_NOEXCEPT; /*! @brief @@ -1005,7 +1009,7 @@ extern uint64_t bt_plugin_get_sink_component_class_count( */ extern const bt_component_class_source * bt_plugin_borrow_source_component_class_by_index_const( - const bt_plugin *plugin, uint64_t index); + const bt_plugin *plugin, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -1037,7 +1041,7 @@ bt_plugin_borrow_source_component_class_by_index_const( */ extern const bt_component_class_filter * bt_plugin_borrow_filter_component_class_by_index_const( - const bt_plugin *plugin, uint64_t index); + const bt_plugin *plugin, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -1069,7 +1073,7 @@ bt_plugin_borrow_filter_component_class_by_index_const( */ extern const bt_component_class_sink * bt_plugin_borrow_sink_component_class_by_index_const( - const bt_plugin *plugin, uint64_t index); + const bt_plugin *plugin, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -1102,7 +1106,7 @@ If no source component class has the name \bt_p{name} within */ extern const bt_component_class_source * bt_plugin_borrow_source_component_class_by_name_const( - const bt_plugin *plugin, const char *name); + const bt_plugin *plugin, const char *name) __BT_NOEXCEPT; /*! @brief @@ -1135,7 +1139,7 @@ If no filter component class has the name \bt_p{name} within */ extern const bt_component_class_filter * bt_plugin_borrow_filter_component_class_by_name_const( - const bt_plugin *plugin, const char *name); + const bt_plugin *plugin, const char *name) __BT_NOEXCEPT; /*! @brief @@ -1168,7 +1172,7 @@ If no sink component class has the name \bt_p{name} within */ extern const bt_component_class_sink * bt_plugin_borrow_sink_component_class_by_name_const( - const bt_plugin *plugin, const char *name); + const bt_plugin *plugin, const char *name) __BT_NOEXCEPT; /*! @} */ @@ -1192,7 +1196,7 @@ bt_plugin_borrow_sink_component_class_by_name_const( @sa bt_plugin_put_ref() — Decrements the reference count of a plugin. */ -extern void bt_plugin_get_ref(const bt_plugin *plugin); +extern void bt_plugin_get_ref(const bt_plugin *plugin) __BT_NOEXCEPT; /*! @brief @@ -1209,7 +1213,7 @@ extern void bt_plugin_get_ref(const bt_plugin *plugin); @sa bt_plugin_get_ref() — Increments the reference count of a plugin. */ -extern void bt_plugin_put_ref(const bt_plugin *plugin); +extern void bt_plugin_put_ref(const bt_plugin *plugin) __BT_NOEXCEPT; /*! @brief @@ -1284,7 +1288,7 @@ This macro effectively moves a plugin reference from the expression @bt_pre_not_null{plugin} */ extern uint64_t bt_plugin_set_get_plugin_count( - const bt_plugin_set *plugin_set); + const bt_plugin_set *plugin_set) __BT_NOEXCEPT; /*! @brief @@ -1311,7 +1315,7 @@ extern uint64_t bt_plugin_set_get_plugin_count( \bt_p{plugin_set} (as returned by bt_plugin_set_get_plugin_count()). */ extern const bt_plugin *bt_plugin_set_borrow_plugin_by_index_const( - const bt_plugin_set *plugin_set, uint64_t index); + const bt_plugin_set *plugin_set, uint64_t index) __BT_NOEXCEPT; /*! @} */ @@ -1335,7 +1339,8 @@ extern const bt_plugin *bt_plugin_set_borrow_plugin_by_index_const( @sa bt_plugin_set_put_ref() — Decrements the reference count of a plugin set. */ -extern void bt_plugin_set_get_ref(const bt_plugin_set *plugin_set); +extern void bt_plugin_set_get_ref(const bt_plugin_set *plugin_set) + __BT_NOEXCEPT; /*! @brief @@ -1352,7 +1357,8 @@ extern void bt_plugin_set_get_ref(const bt_plugin_set *plugin_set); @sa bt_plugin_set_get_ref() — Increments the reference count of a plugin set. */ -extern void bt_plugin_set_put_ref(const bt_plugin_set *plugin_set); +extern void bt_plugin_set_put_ref(const bt_plugin_set *plugin_set) + __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/trace-ir/clock-class.h b/include/babeltrace2/trace-ir/clock-class.h index 129df37a..a54e8b89 100644 --- a/include/babeltrace2/trace-ir/clock-class.h +++ b/include/babeltrace2/trace-ir/clock-class.h @@ -326,7 +326,8 @@ On success, the returned clock class has the following property values: @bt_pre_not_null{self_component} */ -extern bt_clock_class *bt_clock_class_create(bt_self_component *self_component); +extern bt_clock_class *bt_clock_class_create(bt_self_component *self_component) + __BT_NOEXCEPT; /*! @} */ @@ -361,7 +362,7 @@ See the \ref api-tir-clock-cls-prop-freq "frequency" property. Returns the frequency of a clock class. */ extern void bt_clock_class_set_frequency(bt_clock_class *clock_class, - uint64_t frequency); + uint64_t frequency) __BT_NOEXCEPT; /*! @brief @@ -381,7 +382,7 @@ See the \ref api-tir-clock-cls-prop-freq "frequency" property. Sets the frequency of a clock class. */ extern uint64_t bt_clock_class_get_frequency( - const bt_clock_class *clock_class); + const bt_clock_class *clock_class) __BT_NOEXCEPT; /*! @brief @@ -409,7 +410,7 @@ See the \ref api-tir-clock-cls-prop-offset "offset" property. Returns the offset of a clock class. */ extern void bt_clock_class_set_offset(bt_clock_class *clock_class, - int64_t offset_seconds, uint64_t offset_cycles); + int64_t offset_seconds, uint64_t offset_cycles) __BT_NOEXCEPT; /*! @brief @@ -436,7 +437,7 @@ See the \ref api-tir-clock-cls-prop-offset "offset" property. Sets the offset of a clock class. */ extern void bt_clock_class_get_offset(const bt_clock_class *clock_class, - int64_t *offset_seconds, uint64_t *offset_cycles); + int64_t *offset_seconds, uint64_t *offset_cycles) __BT_NOEXCEPT; /*! @brief @@ -457,7 +458,7 @@ See the \ref api-tir-clock-cls-prop-precision "precision" property. Returns the precision of a clock class. */ extern void bt_clock_class_set_precision(bt_clock_class *clock_class, - uint64_t precision); + uint64_t precision) __BT_NOEXCEPT; /*! @brief @@ -478,7 +479,7 @@ See the \ref api-tir-clock-cls-prop-precision "precision" property. Sets the precision of a clock class. */ extern uint64_t bt_clock_class_get_precision( - const bt_clock_class *clock_class); + const bt_clock_class *clock_class) __BT_NOEXCEPT; /*! @brief @@ -503,7 +504,7 @@ property. Unix epoch. */ extern void bt_clock_class_set_origin_is_unix_epoch(bt_clock_class *clock_class, - bt_bool origin_is_unix_epoch); + bt_bool origin_is_unix_epoch) __BT_NOEXCEPT; /*! @brief @@ -527,7 +528,7 @@ property. Sets whether or not the origin of a clock class is the Unix epoch. */ extern bt_bool bt_clock_class_origin_is_unix_epoch( - const bt_clock_class *clock_class); + const bt_clock_class *clock_class) __BT_NOEXCEPT; /*! @brief @@ -572,7 +573,7 @@ See the \ref api-tir-clock-cls-prop-name "name" property. Returns the name of a clock class. */ extern bt_clock_class_set_name_status bt_clock_class_set_name( - bt_clock_class *clock_class, const char *name); + bt_clock_class *clock_class, const char *name) __BT_NOEXCEPT; /*! @brief @@ -599,7 +600,7 @@ If \bt_p{clock_class} has no name, this function returns \c NULL. Sets the name of a clock class. */ extern const char *bt_clock_class_get_name( - const bt_clock_class *clock_class); + const bt_clock_class *clock_class) __BT_NOEXCEPT; /*! @brief @@ -644,7 +645,8 @@ See the \ref api-tir-clock-cls-prop-descr "description" property. Returns the description of a clock class. */ extern bt_clock_class_set_description_status bt_clock_class_set_description( - bt_clock_class *clock_class, const char *description); + bt_clock_class *clock_class, const char *description) + __BT_NOEXCEPT; /*! @brief @@ -671,7 +673,7 @@ If \bt_p{clock_class} has no description, this function returns \c NULL. Sets the description of a clock class. */ extern const char *bt_clock_class_get_description( - const bt_clock_class *clock_class); + const bt_clock_class *clock_class) __BT_NOEXCEPT; /*! @brief @@ -694,7 +696,7 @@ See the \ref api-tir-clock-cls-prop-uuid "UUID" property. Returns the UUID of a clock class. */ extern void bt_clock_class_set_uuid(bt_clock_class *clock_class, - bt_uuid uuid); + bt_uuid uuid) __BT_NOEXCEPT; /*! @brief @@ -721,7 +723,7 @@ If \bt_p{clock_class} has no UUID, this function returns \c NULL. Sets the UUID of a clock class. */ extern bt_uuid bt_clock_class_get_uuid( - const bt_clock_class *clock_class); + const bt_clock_class *clock_class) __BT_NOEXCEPT; /*! @brief @@ -753,7 +755,8 @@ property. Borrows the user attributes of a clock class. */ extern void bt_clock_class_set_user_attributes( - bt_clock_class *clock_class, const bt_value *user_attributes); + bt_clock_class *clock_class, const bt_value *user_attributes) + __BT_NOEXCEPT; /*! @brief @@ -780,7 +783,7 @@ property. \c const version of this function. */ extern bt_value *bt_clock_class_borrow_user_attributes( - bt_clock_class *clock_class); + bt_clock_class *clock_class) __BT_NOEXCEPT; /*! @brief @@ -790,7 +793,7 @@ extern bt_value *bt_clock_class_borrow_user_attributes( See bt_clock_class_borrow_user_attributes(). */ extern const bt_value *bt_clock_class_borrow_user_attributes_const( - const bt_clock_class *clock_class); + const bt_clock_class *clock_class) __BT_NOEXCEPT; /*! @} */ @@ -870,7 +873,7 @@ code if any step of the computation process causes an integer overflow. extern bt_clock_class_cycles_to_ns_from_origin_status bt_clock_class_cycles_to_ns_from_origin( const bt_clock_class *clock_class, - uint64_t value, int64_t *ns_from_origin); + uint64_t value, int64_t *ns_from_origin) __BT_NOEXCEPT; /*! @} */ @@ -894,7 +897,8 @@ bt_clock_class_cycles_to_ns_from_origin( @sa bt_clock_class_put_ref() — Decrements the reference count of a clock class. */ -extern void bt_clock_class_get_ref(const bt_clock_class *clock_class); +extern void bt_clock_class_get_ref( + const bt_clock_class *clock_class) __BT_NOEXCEPT; /*! @brief @@ -911,7 +915,8 @@ extern void bt_clock_class_get_ref(const bt_clock_class *clock_class); @sa bt_clock_class_get_ref() — Increments the reference count of a clock class. */ -extern void bt_clock_class_put_ref(const bt_clock_class *clock_class); +extern void bt_clock_class_put_ref( + const bt_clock_class *clock_class) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/trace-ir/clock-snapshot.h b/include/babeltrace2/trace-ir/clock-snapshot.h index f04204c9..79bf17fc 100644 --- a/include/babeltrace2/trace-ir/clock-snapshot.h +++ b/include/babeltrace2/trace-ir/clock-snapshot.h @@ -107,7 +107,7 @@ properties of its class. @bt_pre_not_null{clock_snapshot} */ extern const bt_clock_class *bt_clock_snapshot_borrow_clock_class_const( - const bt_clock_snapshot *clock_snapshot); + const bt_clock_snapshot *clock_snapshot) __BT_NOEXCEPT; /*! @brief @@ -127,7 +127,7 @@ extern const bt_clock_class *bt_clock_snapshot_borrow_clock_class_const( clock snapshot's value. */ extern uint64_t bt_clock_snapshot_get_value( - const bt_clock_snapshot *clock_snapshot); + const bt_clock_snapshot *clock_snapshot) __BT_NOEXCEPT; /*! @brief @@ -203,7 +203,7 @@ code if any step of the computation process causes an integer overflow. extern bt_clock_snapshot_get_ns_from_origin_status bt_clock_snapshot_get_ns_from_origin( const bt_clock_snapshot *clock_snapshot, - int64_t *ns_from_origin); + int64_t *ns_from_origin) __BT_NOEXCEPT; /*! @} */ diff --git a/include/babeltrace2/trace-ir/event-class.h b/include/babeltrace2/trace-ir/event-class.h index 31a61fc2..f4e815d5 100644 --- a/include/babeltrace2/trace-ir/event-class.h +++ b/include/babeltrace2/trace-ir/event-class.h @@ -259,7 +259,7 @@ On success, the returned event class has the following property values: stream class. */ extern bt_event_class *bt_event_class_create( - bt_stream_class *stream_class); + bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -332,7 +332,7 @@ On success, the returned event class has the following property values: stream class. */ extern bt_event_class *bt_event_class_create_with_id( - bt_stream_class *stream_class, uint64_t id); + bt_stream_class *stream_class, uint64_t id) __BT_NOEXCEPT; /*! @} */ @@ -358,7 +358,7 @@ extern bt_event_class *bt_event_class_create_with_id( \c const version of this function. */ extern bt_stream_class *bt_event_class_borrow_stream_class( - bt_event_class *event_class); + bt_event_class *event_class) __BT_NOEXCEPT; /*! @brief @@ -368,7 +368,7 @@ extern bt_stream_class *bt_event_class_borrow_stream_class( See bt_event_class_borrow_stream_class(). */ extern const bt_stream_class *bt_event_class_borrow_stream_class_const( - const bt_event_class *event_class); + const bt_event_class *event_class) __BT_NOEXCEPT; /*! @} */ @@ -395,7 +395,8 @@ See the \ref api-tir-ev-cls-prop-id "numeric ID" property. Creates an event class with a specific numeric ID and adds it to a stream class. */ -extern uint64_t bt_event_class_get_id(const bt_event_class *event_class); +extern uint64_t bt_event_class_get_id( + const bt_event_class *event_class) __BT_NOEXCEPT; /*! @brief @@ -440,7 +441,7 @@ See the \ref api-tir-ev-cls-prop-name "name" property. Returns the name of an event class. */ extern bt_event_class_set_name_status bt_event_class_set_name( - bt_event_class *event_class, const char *name); + bt_event_class *event_class, const char *name) __BT_NOEXCEPT; /*! @brief @@ -466,7 +467,8 @@ If \bt_p{event_class} has no name, this function returns \c NULL. @sa bt_event_class_set_name() — Sets the name of an event class. */ -extern const char *bt_event_class_get_name(const bt_event_class *event_class); +extern const char *bt_event_class_get_name( + const bt_event_class *event_class) __BT_NOEXCEPT; /*! @brief @@ -588,7 +590,7 @@ See the \ref api-tir-ev-cls-prop-log-lvl "log level" property. Returns the log level of an event class. */ extern void bt_event_class_set_log_level(bt_event_class *event_class, - bt_event_class_log_level log_level); + bt_event_class_log_level log_level) __BT_NOEXCEPT; /*! @brief @@ -616,7 +618,7 @@ See the \ref api-tir-ev-cls-prop-log-lvl "log level" property. */ extern bt_property_availability bt_event_class_get_log_level( const bt_event_class *event_class, - bt_event_class_log_level *log_level); + bt_event_class_log_level *log_level) __BT_NOEXCEPT; /*! @brief @@ -661,7 +663,7 @@ See the \ref api-tir-ev-cls-prop-emf-uri "EMF URI" property. Returns the EMF URI of an event class. */ extern bt_event_class_set_emf_uri_status bt_event_class_set_emf_uri( - bt_event_class *event_class, const char *emf_uri); + bt_event_class *event_class, const char *emf_uri) __BT_NOEXCEPT; /*! @brief @@ -689,7 +691,7 @@ If \bt_p{event_class} has no EMF URI, this function returns \c NULL. Sets the EMF URI of an event class. */ extern const char *bt_event_class_get_emf_uri( - const bt_event_class *event_class); + const bt_event_class *event_class) __BT_NOEXCEPT; /*! @brief @@ -751,7 +753,7 @@ See the \ref api-tir-ev-cls-prop-p-fc "payload field class" property. */ extern bt_event_class_set_field_class_status bt_event_class_set_payload_field_class(bt_event_class *event_class, - bt_field_class *field_class); + bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief @@ -777,7 +779,7 @@ returns \c NULL. \c const version of this function. */ extern bt_field_class *bt_event_class_borrow_payload_field_class( - bt_event_class *event_class); + bt_event_class *event_class) __BT_NOEXCEPT; /*! @brief @@ -787,7 +789,7 @@ extern bt_field_class *bt_event_class_borrow_payload_field_class( See bt_event_class_borrow_payload_field_class(). */ extern const bt_field_class *bt_event_class_borrow_payload_field_class_const( - const bt_event_class *event_class); + const bt_event_class *event_class) __BT_NOEXCEPT; /*! @brief @@ -831,7 +833,7 @@ property. */ extern bt_event_class_set_field_class_status bt_event_class_set_specific_context_field_class(bt_event_class *event_class, - bt_field_class *field_class); + bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief @@ -859,7 +861,8 @@ returns \c NULL. \c const version of this function. */ extern bt_field_class * -bt_event_class_borrow_specific_context_field_class(bt_event_class *event_class); +bt_event_class_borrow_specific_context_field_class( + bt_event_class *event_class) __BT_NOEXCEPT; /*! @brief @@ -870,7 +873,7 @@ See bt_event_class_borrow_specific_context_field_class(). */ extern const bt_field_class * bt_event_class_borrow_specific_context_field_class_const( - const bt_event_class *event_class); + const bt_event_class *event_class) __BT_NOEXCEPT; /*! @brief @@ -901,7 +904,8 @@ See the \ref api-tir-ev-cls-prop-user-attrs "user attributes" property. Borrows the user attributes of an event class. */ extern void bt_event_class_set_user_attributes( - bt_event_class *event_class, const bt_value *user_attributes); + bt_event_class *event_class, const bt_value *user_attributes) + __BT_NOEXCEPT; /*! @brief @@ -928,7 +932,7 @@ See the \ref api-tir-ev-cls-prop-user-attrs "user attributes" property. \c const version of this function. */ extern bt_value *bt_event_class_borrow_user_attributes( - bt_event_class *event_class); + bt_event_class *event_class) __BT_NOEXCEPT; /*! @brief @@ -938,7 +942,7 @@ extern bt_value *bt_event_class_borrow_user_attributes( See bt_event_class_borrow_user_attributes(). */ extern const bt_value *bt_event_class_borrow_user_attributes_const( - const bt_event_class *event_class); + const bt_event_class *event_class) __BT_NOEXCEPT; /*! @} */ @@ -962,7 +966,8 @@ extern const bt_value *bt_event_class_borrow_user_attributes_const( @sa bt_event_class_put_ref() — Decrements the reference count of an event class. */ -extern void bt_event_class_get_ref(const bt_event_class *event_class); +extern void bt_event_class_get_ref( + const bt_event_class *event_class) __BT_NOEXCEPT; /*! @brief @@ -979,7 +984,8 @@ extern void bt_event_class_get_ref(const bt_event_class *event_class); @sa bt_event_class_get_ref() — Increments the reference count of an event class. */ -extern void bt_event_class_put_ref(const bt_event_class *event_class); +extern void bt_event_class_put_ref( + const bt_event_class *event_class) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/trace-ir/event.h b/include/babeltrace2/trace-ir/event.h index c571ca0b..bcb2af3d 100644 --- a/include/babeltrace2/trace-ir/event.h +++ b/include/babeltrace2/trace-ir/event.h @@ -169,7 +169,7 @@ An event has the following properties: @sa bt_event_borrow_class_const() — \c const version of this function. */ -extern bt_event_class *bt_event_borrow_class(bt_event *event); +extern bt_event_class *bt_event_borrow_class(bt_event *event) __BT_NOEXCEPT; /*! @brief @@ -179,7 +179,7 @@ extern bt_event_class *bt_event_borrow_class(bt_event *event); See bt_event_borrow_class(). */ extern const bt_event_class *bt_event_borrow_class_const( - const bt_event *event); + const bt_event *event) __BT_NOEXCEPT; /*! @} */ @@ -205,7 +205,7 @@ extern const bt_event_class *bt_event_borrow_class_const( @sa bt_event_borrow_stream_const() — \c const version of this function. */ -extern bt_stream *bt_event_borrow_stream(bt_event *event); +extern bt_stream *bt_event_borrow_stream(bt_event *event) __BT_NOEXCEPT; /*! @brief @@ -215,7 +215,7 @@ extern bt_stream *bt_event_borrow_stream(bt_event *event); See bt_event_borrow_stream(). */ extern const bt_stream *bt_event_borrow_stream_const( - const bt_event *event); + const bt_event *event) __BT_NOEXCEPT; /*! @} */ @@ -245,7 +245,7 @@ extern const bt_stream *bt_event_borrow_stream_const( @sa bt_event_borrow_packet_const() — \c const version of this function. */ -extern bt_packet *bt_event_borrow_packet(bt_event *event); +extern bt_packet *bt_event_borrow_packet(bt_event *event) __BT_NOEXCEPT; /*! @brief @@ -255,7 +255,7 @@ extern bt_packet *bt_event_borrow_packet(bt_event *event); See bt_event_borrow_packet(). */ extern const bt_packet *bt_event_borrow_packet_const( - const bt_event *event); + const bt_event *event) __BT_NOEXCEPT; /*! @} */ @@ -282,7 +282,7 @@ See the \ref api-tir-ev-prop-payload "payload field" property. @sa bt_event_borrow_payload_field_const() — \c const version of this function. */ -extern bt_field *bt_event_borrow_payload_field(bt_event *event); +extern bt_field *bt_event_borrow_payload_field(bt_event *event) __BT_NOEXCEPT; /*! @brief @@ -292,7 +292,7 @@ extern bt_field *bt_event_borrow_payload_field(bt_event *event); See bt_event_borrow_payload_field(). */ extern const bt_field *bt_event_borrow_payload_field_const( - const bt_event *event); + const bt_event *event) __BT_NOEXCEPT; /*! @brief @@ -313,7 +313,7 @@ See the \ref api-tir-ev-prop-spec-ctx "specific context field" property. \c const version of this function. */ extern bt_field * -bt_event_borrow_specific_context_field(bt_event *event); +bt_event_borrow_specific_context_field(bt_event *event) __BT_NOEXCEPT; /*! @brief @@ -323,7 +323,7 @@ bt_event_borrow_specific_context_field(bt_event *event); See bt_event_borrow_specific_context_field(). */ extern const bt_field *bt_event_borrow_specific_context_field_const( - const bt_event *event); + const bt_event *event) __BT_NOEXCEPT; /*! @brief @@ -344,7 +344,7 @@ See the \ref api-tir-ev-prop-common-ctx "common context field" property. \c const version of this function. */ extern bt_field * -bt_event_borrow_common_context_field(bt_event *event); +bt_event_borrow_common_context_field(bt_event *event) __BT_NOEXCEPT; /*! @brief @@ -354,7 +354,7 @@ bt_event_borrow_common_context_field(bt_event *event); See bt_event_borrow_common_context_field(). */ extern const bt_field *bt_event_borrow_common_context_field_const( - const bt_event *event); + const bt_event *event) __BT_NOEXCEPT; /*! @} */ diff --git a/include/babeltrace2/trace-ir/field-class.h b/include/babeltrace2/trace-ir/field-class.h index c13e6e5e..fdd20995 100644 --- a/include/babeltrace2/trace-ir/field-class.h +++ b/include/babeltrace2/trace-ir/field-class.h @@ -1497,7 +1497,7 @@ typedef enum bt_field_class_type { given type. */ extern bt_field_class_type bt_field_class_get_type( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief @@ -1526,7 +1526,7 @@ returns #BT_TRUE. */ static inline bt_bool bt_field_class_type_is(const bt_field_class_type type, - const bt_field_class_type other_type) + const bt_field_class_type other_type) __BT_NOEXCEPT { return (type & other_type) == other_type; } @@ -1567,7 +1567,8 @@ See the \ref api-tir-fc-prop-user-attrs "user attributes" property. Borrows the user attributes of a field class. */ extern void bt_field_class_set_user_attributes( - bt_field_class *field_class, const bt_value *user_attributes); + bt_field_class *field_class, + const bt_value *user_attributes) __BT_NOEXCEPT; /*! @brief @@ -1594,7 +1595,7 @@ See the \ref api-tir-fc-prop-user-attrs "user attributes" property. \c const version of this function. */ extern bt_value *bt_field_class_borrow_user_attributes( - bt_field_class *field_class); + bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief @@ -1604,7 +1605,7 @@ extern bt_value *bt_field_class_borrow_user_attributes( See bt_field_class_borrow_user_attributes(). */ extern const bt_value *bt_field_class_borrow_user_attributes_const( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @} */ @@ -1638,7 +1639,7 @@ property value: @bt_pre_not_null{trace_class} */ extern bt_field_class *bt_field_class_bool_create( - bt_trace_class *trace_class); + bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @} @@ -1683,7 +1684,7 @@ property values: 0 < \bt_p{length} ≤ 64. */ extern bt_field_class *bt_field_class_bit_array_create( - bt_trace_class *trace_class, uint64_t length); + bt_trace_class *trace_class, uint64_t length) __BT_NOEXCEPT; /*! @brief @@ -1701,7 +1702,7 @@ See the \ref api-tir-fc-ba-prop-len "length" property. @bt_pre_is_ba_fc{field_class} */ extern uint64_t bt_field_class_bit_array_get_length( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @} @@ -1745,7 +1746,7 @@ See the \ref api-tir-fc-int-prop-size "field value range" property. Returns the field value range of an integer field class. */ extern void bt_field_class_integer_set_field_value_range( - bt_field_class *field_class, uint64_t n); + bt_field_class *field_class, uint64_t n) __BT_NOEXCEPT; /*! @brief @@ -1776,7 +1777,7 @@ See the \ref api-tir-fc-int-prop-size "field value range" property. Sets the field value range of an integer field class. */ extern uint64_t bt_field_class_integer_get_field_value_range( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief @@ -1830,7 +1831,8 @@ See the \ref api-tir-fc-int-prop-base "preferred display base" property. */ extern void bt_field_class_integer_set_preferred_display_base( bt_field_class *field_class, - bt_field_class_integer_preferred_display_base preferred_display_base); + bt_field_class_integer_preferred_display_base preferred_display_base) + __BT_NOEXCEPT; /*! @brief @@ -1859,7 +1861,7 @@ See the \ref api-tir-fc-int-prop-base "preferred display base" property. */ extern bt_field_class_integer_preferred_display_base bt_field_class_integer_get_preferred_display_base( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @} */ @@ -1899,7 +1901,7 @@ property values: @bt_pre_not_null{trace_class} */ extern bt_field_class *bt_field_class_integer_unsigned_create( - bt_trace_class *trace_class); + bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @} */ @@ -1939,7 +1941,7 @@ property values: @bt_pre_not_null{trace_class} */ extern bt_field_class *bt_field_class_integer_signed_create( - bt_trace_class *trace_class); + bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @} */ @@ -1976,7 +1978,7 @@ following property value: @bt_pre_not_null{trace_class} */ extern bt_field_class *bt_field_class_real_single_precision_create( - bt_trace_class *trace_class); + bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @} */ @@ -2013,7 +2015,7 @@ following property value: @bt_pre_not_null{trace_class} */ extern bt_field_class *bt_field_class_real_double_precision_create( - bt_trace_class *trace_class); + bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @} */ @@ -2103,7 +2105,7 @@ See the \ref api-tir-fc-enum-prop-mappings "mappings" property. @bt_pre_is_enum_fc{field_class} */ extern uint64_t bt_field_class_enumeration_get_mapping_count( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief @@ -2124,7 +2126,8 @@ See the \ref api-tir-fc-enum-prop-mappings "mappings" property. @bt_pre_not_null{mapping} */ extern const char *bt_field_class_enumeration_mapping_get_label( - const bt_field_class_enumeration_mapping *mapping); + const bt_field_class_enumeration_mapping *mapping) + __BT_NOEXCEPT; /*! @} */ @@ -2169,7 +2172,7 @@ following property values: @bt_pre_not_null{trace_class} */ extern bt_field_class *bt_field_class_enumeration_unsigned_create( - bt_trace_class *trace_class); + bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @brief @@ -2205,7 +2208,7 @@ See the \ref api-tir-fc-enum-prop-mappings "mappings" property. extern bt_field_class_enumeration_add_mapping_status bt_field_class_enumeration_unsigned_add_mapping( bt_field_class *field_class, const char *label, - const bt_integer_range_set_unsigned *ranges); + const bt_integer_range_set_unsigned *ranges) __BT_NOEXCEPT; /*! @brief @@ -2242,7 +2245,8 @@ See the \ref api-tir-fc-enum-prop-mappings "mappings" property. */ extern const bt_field_class_enumeration_unsigned_mapping * bt_field_class_enumeration_unsigned_borrow_mapping_by_index_const( - const bt_field_class *field_class, uint64_t index); + const bt_field_class *field_class, uint64_t index) + __BT_NOEXCEPT; /*! @brief @@ -2276,7 +2280,8 @@ If there's no mapping having the label \bt_p{label} in */ extern const bt_field_class_enumeration_unsigned_mapping * bt_field_class_enumeration_unsigned_borrow_mapping_by_label_const( - const bt_field_class *field_class, const char *label); + const bt_field_class *field_class, const char *label) + __BT_NOEXCEPT; /*! @brief @@ -2329,7 +2334,7 @@ extern bt_field_class_enumeration_get_mapping_labels_for_value_status bt_field_class_enumeration_unsigned_get_mapping_labels_for_value( const bt_field_class *field_class, uint64_t value, bt_field_class_enumeration_mapping_label_array *labels, - uint64_t *count); + uint64_t *count) __BT_NOEXCEPT; /*! @} */ @@ -2363,7 +2368,8 @@ See the \ref api-tir-fc-enum-prop-mappings "mappings" property. */ extern const bt_integer_range_set_unsigned * bt_field_class_enumeration_unsigned_mapping_borrow_ranges_const( - const bt_field_class_enumeration_unsigned_mapping *mapping); + const bt_field_class_enumeration_unsigned_mapping *mapping) + __BT_NOEXCEPT; /*! @brief @@ -2387,6 +2393,7 @@ static inline const bt_field_class_enumeration_mapping * bt_field_class_enumeration_unsigned_mapping_as_mapping_const( const bt_field_class_enumeration_unsigned_mapping *mapping) + __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_field_class_enumeration_mapping, mapping); } @@ -2434,7 +2441,7 @@ following property values: @bt_pre_not_null{trace_class} */ extern bt_field_class *bt_field_class_enumeration_signed_create( - bt_trace_class *trace_class); + bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @brief @@ -2470,7 +2477,7 @@ See the \ref api-tir-fc-enum-prop-mappings "mappings" property. extern bt_field_class_enumeration_add_mapping_status bt_field_class_enumeration_signed_add_mapping( bt_field_class *field_class, const char *label, - const bt_integer_range_set_signed *ranges); + const bt_integer_range_set_signed *ranges) __BT_NOEXCEPT; /*! @brief @@ -2507,7 +2514,8 @@ See the \ref api-tir-fc-enum-prop-mappings "mappings" property. */ extern const bt_field_class_enumeration_signed_mapping * bt_field_class_enumeration_signed_borrow_mapping_by_index_const( - const bt_field_class *field_class, uint64_t index); + const bt_field_class *field_class, uint64_t index) + __BT_NOEXCEPT; /*! @brief @@ -2541,7 +2549,8 @@ If there's no mapping having the label \bt_p{label} in */ extern const bt_field_class_enumeration_signed_mapping * bt_field_class_enumeration_signed_borrow_mapping_by_label_const( - const bt_field_class *field_class, const char *label); + const bt_field_class *field_class, const char *label) + __BT_NOEXCEPT; /*! @brief @@ -2594,7 +2603,7 @@ extern bt_field_class_enumeration_get_mapping_labels_for_value_status bt_field_class_enumeration_signed_get_mapping_labels_for_value( const bt_field_class *field_class, int64_t value, bt_field_class_enumeration_mapping_label_array *labels, - uint64_t *count); + uint64_t *count) __BT_NOEXCEPT; /*! @} */ @@ -2628,7 +2637,8 @@ See the \ref api-tir-fc-enum-prop-mappings "mappings" property. */ extern const bt_integer_range_set_signed * bt_field_class_enumeration_signed_mapping_borrow_ranges_const( - const bt_field_class_enumeration_signed_mapping *mapping); + const bt_field_class_enumeration_signed_mapping *mapping) + __BT_NOEXCEPT; /*! @brief @@ -2652,6 +2662,7 @@ static inline const bt_field_class_enumeration_mapping * bt_field_class_enumeration_signed_mapping_as_mapping_const( const bt_field_class_enumeration_signed_mapping *mapping) + __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_field_class_enumeration_mapping, mapping); } @@ -2688,7 +2699,7 @@ value: @bt_pre_not_null{trace_class} */ extern bt_field_class *bt_field_class_string_create( - bt_trace_class *trace_class); + bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @} */ @@ -2718,7 +2729,7 @@ property. \c const version of this function. */ extern bt_field_class *bt_field_class_array_borrow_element_field_class( - bt_field_class *field_class); + bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief @@ -2729,7 +2740,7 @@ See bt_field_class_array_borrow_element_field_class(). */ extern const bt_field_class * bt_field_class_array_borrow_element_field_class_const( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @} */ @@ -2781,7 +2792,8 @@ bt_pre_fc_not_in_tc{element_field_class} */ extern bt_field_class *bt_field_class_array_static_create( bt_trace_class *trace_class, - bt_field_class *element_field_class, uint64_t length); + bt_field_class *element_field_class, uint64_t length) + __BT_NOEXCEPT; /*! @brief @@ -2799,7 +2811,7 @@ See the \ref api-tir-fc-sarray-prop-len "length" property. @bt_pre_is_sarray_fc{field_class} */ extern uint64_t bt_field_class_array_static_get_length( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @} */ @@ -2869,7 +2881,7 @@ property values: extern bt_field_class *bt_field_class_array_dynamic_create( bt_trace_class *trace_class, bt_field_class *element_field_class, - bt_field_class *length_field_class); + bt_field_class *length_field_class) __BT_NOEXCEPT; /*! @} */ @@ -2907,7 +2919,7 @@ In the meantime, this function returns \c NULL. */ extern const bt_field_path * bt_field_class_array_dynamic_with_length_field_borrow_length_field_path_const( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @} */ @@ -2944,7 +2956,7 @@ property values: @bt_pre_not_null{trace_class} */ extern bt_field_class *bt_field_class_structure_create( - bt_trace_class *trace_class); + bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @brief @@ -2997,8 +3009,9 @@ See the \ref api-tir-fc-struct-prop-members "members" property. */ extern bt_field_class_structure_append_member_status bt_field_class_structure_append_member( - bt_field_class *field_class, - const char *name, bt_field_class *member_field_class); + bt_field_class *field_class, + const char *name, bt_field_class *member_field_class) + __BT_NOEXCEPT; /*! @brief @@ -3018,7 +3031,7 @@ See the \ref api-tir-fc-struct-prop-members "members" property. @bt_pre_is_struct_fc{field_class} */ extern uint64_t bt_field_class_structure_get_member_count( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief @@ -3056,7 +3069,7 @@ See the \ref api-tir-fc-struct-prop-members "members" property. */ extern bt_field_class_structure_member * bt_field_class_structure_borrow_member_by_index( - bt_field_class *field_class, uint64_t index); + bt_field_class *field_class, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -3067,7 +3080,8 @@ See bt_field_class_structure_borrow_member_by_index(). */ extern const bt_field_class_structure_member * bt_field_class_structure_borrow_member_by_index_const( - const bt_field_class *field_class, uint64_t index); + const bt_field_class *field_class, uint64_t index) + __BT_NOEXCEPT; /*! @brief @@ -3104,7 +3118,7 @@ If there's no member having the name \bt_p{name} in */ extern bt_field_class_structure_member * bt_field_class_structure_borrow_member_by_name( - bt_field_class *field_class, const char *name); + bt_field_class *field_class, const char *name) __BT_NOEXCEPT; /*! @brief @@ -3115,7 +3129,8 @@ See bt_field_class_structure_borrow_member_by_name(). */ extern const bt_field_class_structure_member * bt_field_class_structure_borrow_member_by_name_const( - const bt_field_class *field_class, const char *name); + const bt_field_class *field_class, const char *name) + __BT_NOEXCEPT; /*! @} */ @@ -3150,7 +3165,7 @@ See the \ref api-tir-fc-struct-prop-members "members" property. @bt_pre_not_null{member} */ extern const char *bt_field_class_structure_member_get_name( - const bt_field_class_structure_member *member); + const bt_field_class_structure_member *member) __BT_NOEXCEPT; /*! @brief @@ -3172,7 +3187,7 @@ See the \ref api-tir-fc-struct-prop-members "members" property. */ extern bt_field_class * bt_field_class_structure_member_borrow_field_class( - bt_field_class_structure_member *member); + bt_field_class_structure_member *member) __BT_NOEXCEPT; /*! @brief @@ -3183,7 +3198,7 @@ See bt_field_class_structure_member_borrow_field_class(). */ extern const bt_field_class * bt_field_class_structure_member_borrow_field_class_const( - const bt_field_class_structure_member *member); + const bt_field_class_structure_member *member) __BT_NOEXCEPT; /*! @brief @@ -3215,8 +3230,8 @@ See the \ref api-tir-fc-struct-prop-members "members" property. Borrows the user attributes of a structure field class member. */ extern void bt_field_class_structure_member_set_user_attributes( - bt_field_class_structure_member *member, - const bt_value *user_attributes); + bt_field_class_structure_member *member, + const bt_value *user_attributes) __BT_NOEXCEPT; /*! @brief @@ -3246,7 +3261,7 @@ See the \ref api-tir-fc-struct-prop-members "members" property. */ extern bt_value * bt_field_class_structure_member_borrow_user_attributes( - bt_field_class_structure_member *member); + bt_field_class_structure_member *member) __BT_NOEXCEPT; /*! @brief @@ -3257,7 +3272,7 @@ See bt_field_class_structure_member_borrow_user_attributes(). */ extern const bt_value * bt_field_class_structure_member_borrow_user_attributes_const( - const bt_field_class_structure_member *member); + const bt_field_class_structure_member *member) __BT_NOEXCEPT; /*! @} */ @@ -3286,7 +3301,7 @@ See the \ref api-tir-fc-opt-prop-fc "optional field class" property. \c const version of this function. */ extern bt_field_class *bt_field_class_option_borrow_field_class( - bt_field_class *field_class); + bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief @@ -3297,7 +3312,7 @@ See bt_field_class_option_borrow_field_class(). */ extern const bt_field_class * bt_field_class_option_borrow_field_class_const( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @} */ @@ -3344,7 +3359,7 @@ values: */ extern bt_field_class *bt_field_class_option_without_selector_create( bt_trace_class *trace_class, - bt_field_class *optional_field_class); + bt_field_class *optional_field_class) __BT_NOEXCEPT; /*! @} */ @@ -3381,7 +3396,7 @@ In the meantime, this function returns \c NULL. */ extern const bt_field_path * bt_field_class_option_with_selector_field_borrow_selector_field_path_const( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @} */ @@ -3443,7 +3458,7 @@ values: extern bt_field_class *bt_field_class_option_with_selector_field_bool_create( bt_trace_class *trace_class, bt_field_class *optional_field_class, - bt_field_class *selector_field_class); + bt_field_class *selector_field_class) __BT_NOEXCEPT; /*! @brief @@ -3469,7 +3484,8 @@ property. */ extern void bt_field_class_option_with_selector_field_bool_set_selector_is_reversed( - bt_field_class *field_class, bt_bool selector_is_reversed); + bt_field_class *field_class, bt_bool selector_is_reversed) + __BT_NOEXCEPT; /*! @brief @@ -3495,7 +3511,7 @@ property. */ extern bt_bool bt_field_class_option_with_selector_field_bool_selector_is_reversed( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @} */ @@ -3566,7 +3582,8 @@ bt_field_class_option_with_selector_field_integer_unsigned_create( bt_trace_class *trace_class, bt_field_class *optional_field_class, bt_field_class *selector_field_class, - const bt_integer_range_set_unsigned *ranges); + const bt_integer_range_set_unsigned *ranges) + __BT_NOEXCEPT; /*! @brief @@ -3588,7 +3605,7 @@ property. */ extern const bt_integer_range_set_unsigned * bt_field_class_option_with_selector_field_integer_unsigned_borrow_selector_ranges_const( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @} */ @@ -3659,7 +3676,7 @@ bt_field_class_option_with_selector_field_integer_signed_create( bt_trace_class *trace_class, bt_field_class *optional_field_class, bt_field_class *selector_field_class, - const bt_integer_range_set_signed *ranges); + const bt_integer_range_set_signed *ranges) __BT_NOEXCEPT; /*! @brief @@ -3681,7 +3698,7 @@ property. */ extern const bt_integer_range_set_signed * bt_field_class_option_with_selector_field_integer_signed_borrow_selector_ranges_const( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @} */ @@ -3743,7 +3760,7 @@ property values: */ extern bt_field_class *bt_field_class_variant_create( bt_trace_class *trace_class, - bt_field_class *selector_field_class); + bt_field_class *selector_field_class) __BT_NOEXCEPT; /*! @brief @@ -3763,7 +3780,7 @@ See the \ref api-tir-fc-var-prop-opts "options" property. @bt_pre_is_var_fc{field_class} */ extern uint64_t bt_field_class_variant_get_option_count( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief @@ -3801,7 +3818,7 @@ See the \ref api-tir-fc-var-prop-opts "options" property. */ extern bt_field_class_variant_option * bt_field_class_variant_borrow_option_by_index( - bt_field_class *field_class, uint64_t index); + bt_field_class *field_class, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -3812,7 +3829,8 @@ See bt_field_class_variant_borrow_option_by_index(). */ extern const bt_field_class_variant_option * bt_field_class_variant_borrow_option_by_index_const( - const bt_field_class *field_class, uint64_t index); + const bt_field_class *field_class, uint64_t index) + __BT_NOEXCEPT; /*! @brief @@ -3849,7 +3867,7 @@ If there's no option having the name \bt_p{name} in */ extern bt_field_class_variant_option * bt_field_class_variant_borrow_option_by_name( - bt_field_class *field_class, const char *name); + bt_field_class *field_class, const char *name) __BT_NOEXCEPT; /*! @brief @@ -3860,7 +3878,8 @@ See bt_field_class_variant_borrow_option_by_name(). */ extern const bt_field_class_variant_option * bt_field_class_variant_borrow_option_by_name_const( - const bt_field_class *field_class, const char *name); + const bt_field_class *field_class, const char *name) + __BT_NOEXCEPT; /*! @} */ @@ -3895,7 +3914,7 @@ See the \ref api-tir-fc-var-prop-opts "options" property. @bt_pre_not_null{option} */ extern const char *bt_field_class_variant_option_get_name( - const bt_field_class_variant_option *option); + const bt_field_class_variant_option *option) __BT_NOEXCEPT; /*! @brief @@ -3916,7 +3935,7 @@ See the \ref api-tir-fc-var-prop-opts "options" property. \c const version of this function. */ extern bt_field_class *bt_field_class_variant_option_borrow_field_class( - bt_field_class_variant_option *option); + bt_field_class_variant_option *option) __BT_NOEXCEPT; /*! @brief @@ -3927,7 +3946,7 @@ See bt_field_class_variant_option_borrow_field_class(). */ extern const bt_field_class * bt_field_class_variant_option_borrow_field_class_const( - const bt_field_class_variant_option *option); + const bt_field_class_variant_option *option) __BT_NOEXCEPT; /*! @brief @@ -3963,7 +3982,7 @@ See the \ref api-tir-fc-var-prop-opts "options" property. */ extern void bt_field_class_variant_option_set_user_attributes( bt_field_class_variant_option *option, - const bt_value *user_attributes); + const bt_value *user_attributes) __BT_NOEXCEPT; /*! @brief @@ -3994,7 +4013,7 @@ See the \ref api-tir-fc-var-prop-opts "options" property. \c const version of this function. */ extern bt_value *bt_field_class_variant_option_borrow_user_attributes( - bt_field_class_variant_option *option); + bt_field_class_variant_option *option) __BT_NOEXCEPT; /*! @brief @@ -4004,7 +4023,7 @@ extern bt_value *bt_field_class_variant_option_borrow_user_attributes( See bt_field_class_variant_option_borrow_user_attributes(). */ extern const bt_value *bt_field_class_variant_option_borrow_user_attributes_const( - const bt_field_class_variant_option *option); + const bt_field_class_variant_option *option) __BT_NOEXCEPT; /*! @} */ @@ -4067,7 +4086,7 @@ See the \ref api-tir-fc-var-prop-opts "options" property. extern bt_field_class_variant_without_selector_append_option_status bt_field_class_variant_without_selector_append_option( bt_field_class *field_class, const char *name, - bt_field_class *option_field_class); + bt_field_class *option_field_class) __BT_NOEXCEPT; /*! @} */ @@ -4125,7 +4144,7 @@ In the meantime, this function returns \c NULL. */ extern const bt_field_path * bt_field_class_variant_with_selector_field_borrow_selector_field_path_const( - const bt_field_class *field_class); + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @} */ @@ -4182,7 +4201,7 @@ extern bt_field_class_variant_with_selector_field_integer_append_option_status bt_field_class_variant_with_selector_field_integer_unsigned_append_option( bt_field_class *field_class, const char *name, bt_field_class *option_field_class, - const bt_integer_range_set_unsigned *ranges); + const bt_integer_range_set_unsigned *ranges) __BT_NOEXCEPT; /*! @brief @@ -4219,7 +4238,8 @@ See the \ref api-tir-fc-var-prop-opts "options" property. */ extern const bt_field_class_variant_with_selector_field_integer_unsigned_option * bt_field_class_variant_with_selector_field_integer_unsigned_borrow_option_by_index_const( - const bt_field_class *field_class, uint64_t index); + const bt_field_class *field_class, uint64_t index) + __BT_NOEXCEPT; /*! @brief @@ -4257,7 +4277,8 @@ If there's no option having the name \bt_p{name} in */ extern const bt_field_class_variant_with_selector_field_integer_unsigned_option * bt_field_class_variant_with_selector_field_integer_unsigned_borrow_option_by_name_const( - const bt_field_class *field_class, const char *name); + const bt_field_class *field_class, const char *name) + __BT_NOEXCEPT; /*! @} */ @@ -4291,7 +4312,8 @@ See the \ref api-tir-fc-var-prop-opts "options" property. */ extern const bt_integer_range_set_unsigned * bt_field_class_variant_with_selector_field_integer_unsigned_option_borrow_ranges_const( - const bt_field_class_variant_with_selector_field_integer_unsigned_option *option); + const bt_field_class_variant_with_selector_field_integer_unsigned_option *option) + __BT_NOEXCEPT; /*! @brief @@ -4315,6 +4337,7 @@ static inline const bt_field_class_variant_option * bt_field_class_variant_with_selector_field_integer_unsigned_option_as_option_const( const bt_field_class_variant_with_selector_field_integer_unsigned_option *option) + __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_field_class_variant_option, option); } @@ -4374,7 +4397,8 @@ extern bt_field_class_variant_with_selector_field_integer_append_option_status bt_field_class_variant_with_selector_field_integer_signed_append_option( bt_field_class *field_class, const char *name, bt_field_class *option_field_class, - const bt_integer_range_set_signed *ranges); + const bt_integer_range_set_signed *ranges) + __BT_NOEXCEPT; /*! @brief @@ -4411,7 +4435,8 @@ See the \ref api-tir-fc-var-prop-opts "options" property. */ extern const bt_field_class_variant_with_selector_field_integer_signed_option * bt_field_class_variant_with_selector_field_integer_signed_borrow_option_by_index_const( - const bt_field_class *field_class, uint64_t index); + const bt_field_class *field_class, uint64_t index) + __BT_NOEXCEPT; /*! @brief @@ -4449,7 +4474,8 @@ If there's no option having the name \bt_p{name} in */ extern const bt_field_class_variant_with_selector_field_integer_signed_option * bt_field_class_variant_with_selector_field_integer_signed_borrow_option_by_name_const( - const bt_field_class *field_class, const char *name); + const bt_field_class *field_class, const char *name) + __BT_NOEXCEPT; /*! @} */ @@ -4483,7 +4509,8 @@ See the \ref api-tir-fc-var-prop-opts "options" property. */ extern const bt_integer_range_set_signed * bt_field_class_variant_with_selector_field_integer_signed_option_borrow_ranges_const( - const bt_field_class_variant_with_selector_field_integer_signed_option *option); + const bt_field_class_variant_with_selector_field_integer_signed_option *option) + __BT_NOEXCEPT; /*! @brief @@ -4507,6 +4534,7 @@ static inline const bt_field_class_variant_option * bt_field_class_variant_with_selector_field_integer_signed_option_as_option_const( const bt_field_class_variant_with_selector_field_integer_signed_option *option) + __BT_NOEXCEPT { return __BT_UPCAST_CONST(bt_field_class_variant_option, option); } @@ -4533,7 +4561,8 @@ bt_field_class_variant_with_selector_field_integer_signed_option_as_option_const @sa bt_field_class_put_ref() — Decrements the reference count of a field class. */ -extern void bt_field_class_get_ref(const bt_field_class *field_class); +extern void bt_field_class_get_ref( + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief @@ -4550,7 +4579,8 @@ extern void bt_field_class_get_ref(const bt_field_class *field_class); @sa bt_field_class_get_ref() — Increments the reference count of a field class. */ -extern void bt_field_class_put_ref(const bt_field_class *field_class); +extern void bt_field_class_put_ref( + const bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/trace-ir/field-path.h b/include/babeltrace2/trace-ir/field-path.h index 4119f541..039ceb50 100644 --- a/include/babeltrace2/trace-ir/field-path.h +++ b/include/babeltrace2/trace-ir/field-path.h @@ -230,7 +230,7 @@ See the \ref api-tir-field-path-prop-root "root scope" property. @bt_pre_not_null{field_path} */ extern bt_field_path_scope bt_field_path_get_root_scope( - const bt_field_path *field_path); + const bt_field_path *field_path) __BT_NOEXCEPT; /*! @brief @@ -248,7 +248,7 @@ See the \ref api-tir-field-path-prop-items "items" property. @bt_pre_not_null{field_path} */ extern uint64_t bt_field_path_get_item_count( - const bt_field_path *field_path); + const bt_field_path *field_path) __BT_NOEXCEPT; /*! @brief @@ -280,7 +280,7 @@ See the \ref api-tir-field-path-prop-items "items" property. Returns the number of items contained in a field path. */ extern const bt_field_path_item *bt_field_path_borrow_item_by_index_const( - const bt_field_path *field_path, uint64_t index); + const bt_field_path *field_path, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -297,7 +297,8 @@ extern const bt_field_path_item *bt_field_path_borrow_item_by_index_const( @sa bt_field_path_put_ref() — Decrements the reference count of a field path. */ -extern void bt_field_path_get_ref(const bt_field_path *field_path); +extern void bt_field_path_get_ref(const bt_field_path *field_path) + __BT_NOEXCEPT; /*! @brief @@ -314,7 +315,8 @@ extern void bt_field_path_get_ref(const bt_field_path *field_path); @sa bt_field_path_get_ref() — Increments the reference count of a field path. */ -extern void bt_field_path_put_ref(const bt_field_path *field_path); +extern void bt_field_path_put_ref(const bt_field_path *field_path) + __BT_NOEXCEPT; /*! @brief @@ -422,7 +424,7 @@ See the \ref api-tir-field-path-prop-items "items" property. @bt_pre_not_null{item} */ extern bt_field_path_item_type bt_field_path_item_get_type( - const bt_field_path_item *item); + const bt_field_path_item *item) __BT_NOEXCEPT; /*! @brief @@ -444,7 +446,7 @@ See the \ref api-tir-field-path-prop-items "items" property. #BT_FIELD_PATH_ITEM_TYPE_INDEX). */ extern uint64_t bt_field_path_item_index_get_index( - const bt_field_path_item *item); + const bt_field_path_item *item) __BT_NOEXCEPT; /*! @} */ diff --git a/include/babeltrace2/trace-ir/field.h b/include/babeltrace2/trace-ir/field.h index e52edfba..dc393439 100644 --- a/include/babeltrace2/trace-ir/field.h +++ b/include/babeltrace2/trace-ir/field.h @@ -444,7 +444,7 @@ bt_field_class_get_type(bt_field_borrow_class(field)) Returns the type enumerator of a \bt_fc. */ extern bt_field_class_type bt_field_get_class_type( - const bt_field *field); + const bt_field *field) __BT_NOEXCEPT; /*! @} */ @@ -468,7 +468,7 @@ extern bt_field_class_type bt_field_get_class_type( @sa bt_field_borrow_class_const() — \c const version of this function. */ -extern bt_field_class *bt_field_borrow_class(bt_field *field); +extern bt_field_class *bt_field_borrow_class(bt_field *field) __BT_NOEXCEPT; /*! @brief @@ -478,7 +478,7 @@ extern bt_field_class *bt_field_borrow_class(bt_field *field); See bt_field_borrow_class(). */ extern const bt_field_class *bt_field_borrow_class_const( - const bt_field *field); + const bt_field *field) __BT_NOEXCEPT; /*! @} */ @@ -504,7 +504,8 @@ extern const bt_field_class *bt_field_borrow_class_const( @sa bt_field_bool_get_value() — Returns the value of a boolean field. */ -extern void bt_field_bool_set_value(bt_field *field, bt_bool value); +extern void bt_field_bool_set_value(bt_field *field, bt_bool value) + __BT_NOEXCEPT; /*! @brief @@ -522,7 +523,7 @@ extern void bt_field_bool_set_value(bt_field *field, bt_bool value); @sa bt_field_bool_set_value() — Sets the value of a boolean field. */ -extern bt_bool bt_field_bool_get_value(const bt_field *field); +extern bt_bool bt_field_bool_get_value(const bt_field *field) __BT_NOEXCEPT; /*! @} */ @@ -553,7 +554,7 @@ See \bt_c_ba_field to learn more. Returns the bits of a bit array field as an integer. */ extern void bt_field_bit_array_set_value_as_integer(bt_field *field, - uint64_t bits); + uint64_t bits) __BT_NOEXCEPT; /*! @brief @@ -577,7 +578,7 @@ See \bt_c_ba_field to learn more. Sets the bits of a bit array field from an integer. */ extern uint64_t bt_field_bit_array_get_value_as_integer( - const bt_field *field); + const bt_field *field) __BT_NOEXCEPT; /*! @} */ @@ -608,7 +609,7 @@ extern uint64_t bt_field_bit_array_get_value_as_integer( Returns the value of an unsigned integer field. */ extern void bt_field_integer_unsigned_set_value(bt_field *field, - uint64_t value); + uint64_t value) __BT_NOEXCEPT; /*! @brief @@ -627,7 +628,7 @@ extern void bt_field_integer_unsigned_set_value(bt_field *field, Sets the value of an unsigned integer field. */ extern uint64_t bt_field_integer_unsigned_get_value( - const bt_field *field); + const bt_field *field) __BT_NOEXCEPT; /*! @brief @@ -651,7 +652,7 @@ extern uint64_t bt_field_integer_unsigned_get_value( Returns the value of an signed integer field. */ extern void bt_field_integer_signed_set_value(bt_field *field, - int64_t value); + int64_t value) __BT_NOEXCEPT; /*! @brief @@ -669,7 +670,8 @@ extern void bt_field_integer_signed_set_value(bt_field *field, @sa bt_field_integer_signed_set_value() — Sets the value of an signed integer field. */ -extern int64_t bt_field_integer_signed_get_value(const bt_field *field); +extern int64_t bt_field_integer_signed_get_value( + const bt_field *field) __BT_NOEXCEPT; /*! @} */ @@ -739,7 +741,7 @@ bt_field_class_enumeration_unsigned_get_mapping_labels_for_value( extern bt_field_enumeration_get_mapping_labels_status bt_field_enumeration_unsigned_get_mapping_labels(const bt_field *field, bt_field_class_enumeration_mapping_label_array *labels, - uint64_t *count); + uint64_t *count) __BT_NOEXCEPT; /*! @brief @@ -782,7 +784,7 @@ bt_field_class_enumeration_signed_get_mapping_labels_for_value( extern bt_field_enumeration_get_mapping_labels_status bt_field_enumeration_signed_get_mapping_labels(const bt_field *field, bt_field_class_enumeration_mapping_label_array *labels, - uint64_t *count); + uint64_t *count) __BT_NOEXCEPT; /*! @} */ @@ -810,7 +812,7 @@ bt_field_enumeration_signed_get_mapping_labels(const bt_field *field, Returns the value of a single-precision real field. */ extern void bt_field_real_single_precision_set_value(bt_field *field, - float value); + float value) __BT_NOEXCEPT; /*! @brief @@ -828,7 +830,8 @@ extern void bt_field_real_single_precision_set_value(bt_field *field, @sa bt_field_real_single_precision_set_value() — Sets the value of a single-precision real field. */ -extern float bt_field_real_single_precision_get_value(const bt_field *field); +extern float bt_field_real_single_precision_get_value( + const bt_field *field) __BT_NOEXCEPT; /*! @brief @@ -849,7 +852,7 @@ extern float bt_field_real_single_precision_get_value(const bt_field *field); Returns the value of a double-precision real field. */ extern void bt_field_real_double_precision_set_value(bt_field *field, - double value); + double value) __BT_NOEXCEPT; /*! @brief @@ -867,7 +870,8 @@ extern void bt_field_real_double_precision_set_value(bt_field *field, @sa bt_field_real_double_precision_set_value() — Sets the value of a double-precision real field. */ -extern double bt_field_real_double_precision_get_value(const bt_field *field); +extern double bt_field_real_double_precision_get_value( + const bt_field *field) __BT_NOEXCEPT; /*! @} */ @@ -922,7 +926,7 @@ typedef enum bt_field_string_set_value_status { Clears a string field. */ extern bt_field_string_set_value_status bt_field_string_set_value( - bt_field *field, const char *value); + bt_field *field, const char *value) __BT_NOEXCEPT; /*! @brief @@ -937,7 +941,7 @@ extern bt_field_string_set_value_status bt_field_string_set_value( @bt_pre_not_null{field} @bt_pre_is_string_field{field} */ -extern uint64_t bt_field_string_get_length(const bt_field *field); +extern uint64_t bt_field_string_get_length(const bt_field *field) __BT_NOEXCEPT; /*! @brief @@ -959,7 +963,8 @@ extern uint64_t bt_field_string_get_length(const bt_field *field); @sa bt_field_string_set_value() — Sets the value of a string field. */ -extern const char *bt_field_string_get_value(const bt_field *field); +extern const char *bt_field_string_get_value( + const bt_field *field) __BT_NOEXCEPT; /*! @brief @@ -1010,7 +1015,7 @@ typedef enum bt_field_string_append_status { Sets the value of a string field. */ extern bt_field_string_append_status bt_field_string_append( - bt_field *field, const char *value); + bt_field *field, const char *value) __BT_NOEXCEPT; /*! @brief @@ -1047,7 +1052,8 @@ extern bt_field_string_append_status bt_field_string_append( Sets the value of a string field. */ extern bt_field_string_append_status bt_field_string_append_with_length( - bt_field *field, const char *value, uint64_t length); + bt_field *field, const char *value, uint64_t length) + __BT_NOEXCEPT; /*! @brief @@ -1064,7 +1070,7 @@ extern bt_field_string_append_status bt_field_string_append_with_length( @sa bt_field_string_set_value() — Sets the value of a string field. */ -extern void bt_field_string_clear(bt_field *field); +extern void bt_field_string_clear(bt_field *field) __BT_NOEXCEPT; /*! @} */ @@ -1086,7 +1092,7 @@ extern void bt_field_string_clear(bt_field *field); @bt_pre_not_null{field} @bt_pre_is_array_field{field} */ -extern uint64_t bt_field_array_get_length(const bt_field *field); +extern uint64_t bt_field_array_get_length(const bt_field *field) __BT_NOEXCEPT; /*! @brief @@ -1121,7 +1127,7 @@ extern uint64_t bt_field_array_get_length(const bt_field *field); \c const version of this function. */ extern bt_field *bt_field_array_borrow_element_field_by_index( - bt_field *field, uint64_t index); + bt_field *field, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -1132,7 +1138,7 @@ See bt_field_array_borrow_element_field_by_index(). */ extern const bt_field * bt_field_array_borrow_element_field_by_index_const( - const bt_field *field, uint64_t index); + const bt_field *field, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -1171,7 +1177,8 @@ typedef enum bt_field_array_dynamic_set_length_status { @bt_pre_hot{field} */ extern bt_field_array_dynamic_set_length_status -bt_field_array_dynamic_set_length(bt_field *field, uint64_t length); +bt_field_array_dynamic_set_length(bt_field *field, uint64_t length) + __BT_NOEXCEPT; /*! @} */ @@ -1211,7 +1218,7 @@ bt_field_array_dynamic_set_length(bt_field *field, uint64_t length); \c const version of this function. */ extern bt_field *bt_field_structure_borrow_member_field_by_index( - bt_field *field, uint64_t index); + bt_field *field, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -1222,7 +1229,7 @@ See bt_field_structure_borrow_member_field_by_index(). */ extern const bt_field * bt_field_structure_borrow_member_field_by_index_const( - const bt_field *field, uint64_t index); + const bt_field *field, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -1255,7 +1262,7 @@ returns \c NULL. \c const version of this function. */ extern bt_field *bt_field_structure_borrow_member_field_by_name( - bt_field *field, const char *name); + bt_field *field, const char *name) __BT_NOEXCEPT; /*! @brief @@ -1266,7 +1273,7 @@ See bt_field_structure_borrow_member_field_by_name(). */ extern const bt_field * bt_field_structure_borrow_member_field_by_name_const( - const bt_field *field, const char *name); + const bt_field *field, const char *name) __BT_NOEXCEPT; /*! @} */ @@ -1288,7 +1295,8 @@ bt_field_structure_borrow_member_field_by_name_const( @bt_pre_not_null{field} @bt_pre_is_opt_field{field} */ -extern void bt_field_option_set_has_field(bt_field *field, bt_bool has_field); +extern void bt_field_option_set_has_field(bt_field *field, bt_bool has_field) + __BT_NOEXCEPT; /*! @brief @@ -1319,7 +1327,7 @@ If \bt_p{field} has no field, this function returns \c NULL. @sa bt_field_option_borrow_field_const() — \c const version of this function. */ -extern bt_field *bt_field_option_borrow_field(bt_field *field); +extern bt_field *bt_field_option_borrow_field(bt_field *field) __BT_NOEXCEPT; /*! @brief @@ -1329,7 +1337,7 @@ extern bt_field *bt_field_option_borrow_field(bt_field *field); See bt_field_option_borrow_field(). */ extern const bt_field * -bt_field_option_borrow_field_const(const bt_field *field); +bt_field_option_borrow_field_const(const bt_field *field) __BT_NOEXCEPT; /*! @} */ @@ -1372,7 +1380,7 @@ typedef enum bt_field_variant_select_option_by_index_status { */ extern bt_field_variant_select_option_by_index_status bt_field_variant_select_option_by_index( - bt_field *field, uint64_t index); + bt_field *field, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -1405,7 +1413,7 @@ bt_field_variant_select_option_by_index( \c const version of this function. */ extern bt_field *bt_field_variant_borrow_selected_option_field( - bt_field *field); + bt_field *field) __BT_NOEXCEPT; /*! @brief @@ -1416,7 +1424,7 @@ See bt_field_variant_borrow_selected_option_field(). */ extern const bt_field * bt_field_variant_borrow_selected_option_field_const( - const bt_field *field); + const bt_field *field) __BT_NOEXCEPT; /*! @brief @@ -1436,7 +1444,7 @@ bt_field_variant_borrow_selected_option_field_const( Borrows the field of a variant field's selected option. */ extern uint64_t bt_field_variant_get_selected_option_index( - const bt_field *field); + const bt_field *field) __BT_NOEXCEPT; /*! @brief @@ -1461,7 +1469,7 @@ bt_field_class_variant_borrow_option_by_index( */ extern const bt_field_class_variant_option * bt_field_variant_borrow_selected_option_class_const( - const bt_field *field); + const bt_field *field) __BT_NOEXCEPT; /*! @brief @@ -1486,7 +1494,7 @@ bt_field_class_variant_with_selector_field_integer_unsigned_borrow_option_by_ind */ extern const bt_field_class_variant_with_selector_field_integer_unsigned_option * bt_field_variant_with_selector_field_integer_unsigned_borrow_selected_option_class_const( - const bt_field *field); + const bt_field *field) __BT_NOEXCEPT; /*! @brief @@ -1511,7 +1519,7 @@ bt_field_class_variant_with_selector_field_integer_signed_borrow_option_by_index */ extern const bt_field_class_variant_with_selector_field_integer_signed_option * bt_field_variant_with_selector_field_integer_signed_borrow_selected_option_class_const( - const bt_field *field); + const bt_field *field) __BT_NOEXCEPT; /*! @} */ diff --git a/include/babeltrace2/trace-ir/packet.h b/include/babeltrace2/trace-ir/packet.h index ce7aba22..80fd0de6 100644 --- a/include/babeltrace2/trace-ir/packet.h +++ b/include/babeltrace2/trace-ir/packet.h @@ -147,7 +147,7 @@ On success, the returned packet has the following property value: bt_stream_class_supports_packets(bt_stream_borrow_class_const(stream)) returns #BT_TRUE. */ -extern bt_packet *bt_packet_create(const bt_stream *stream); +extern bt_packet *bt_packet_create(const bt_stream *stream) __BT_NOEXCEPT; /*! @} */ @@ -173,7 +173,7 @@ extern bt_packet *bt_packet_create(const bt_stream *stream); @sa bt_packet_borrow_stream_const() — \c const version of this function. */ -extern bt_stream *bt_packet_borrow_stream(bt_packet *packet); +extern bt_stream *bt_packet_borrow_stream(bt_packet *packet) __BT_NOEXCEPT; /*! @brief @@ -183,7 +183,7 @@ extern bt_stream *bt_packet_borrow_stream(bt_packet *packet); See bt_packet_borrow_stream(). */ extern const bt_stream *bt_packet_borrow_stream_const( - const bt_packet *packet); + const bt_packet *packet) __BT_NOEXCEPT; /*! @} */ @@ -211,7 +211,7 @@ See the \ref api-tir-pkt-prop-ctx "context field" property. \c const version of this function. */ extern -bt_field *bt_packet_borrow_context_field(bt_packet *packet); +bt_field *bt_packet_borrow_context_field(bt_packet *packet) __BT_NOEXCEPT; /*! @brief @@ -222,7 +222,7 @@ See bt_packet_borrow_context_field(). */ extern const bt_field *bt_packet_borrow_context_field_const( - const bt_packet *packet); + const bt_packet *packet) __BT_NOEXCEPT; /*! @} */ @@ -246,7 +246,7 @@ const bt_field *bt_packet_borrow_context_field_const( @sa bt_packet_put_ref() — Decrements the reference count of a packet. */ -extern void bt_packet_get_ref(const bt_packet *packet); +extern void bt_packet_get_ref(const bt_packet *packet) __BT_NOEXCEPT; /*! @brief @@ -263,7 +263,7 @@ extern void bt_packet_get_ref(const bt_packet *packet); @sa bt_packet_get_ref() — Increments the reference count of a packet. */ -extern void bt_packet_put_ref(const bt_packet *packet); +extern void bt_packet_put_ref(const bt_packet *packet) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/trace-ir/stream-class.h b/include/babeltrace2/trace-ir/stream-class.h index 0df1f197..e74d3cc3 100644 --- a/include/babeltrace2/trace-ir/stream-class.h +++ b/include/babeltrace2/trace-ir/stream-class.h @@ -561,7 +561,7 @@ On success, the returned stream class has the following property values: trace class. */ extern bt_stream_class *bt_stream_class_create( - bt_trace_class *trace_class); + bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @brief @@ -658,7 +658,7 @@ On success, the returned stream class has the following property values: trace class. */ extern bt_stream_class *bt_stream_class_create_with_id( - bt_trace_class *trace_class, uint64_t id); + bt_trace_class *trace_class, uint64_t id) __BT_NOEXCEPT; /*! @} */ @@ -684,7 +684,7 @@ extern bt_stream_class *bt_stream_class_create_with_id( \c const version of this function. */ extern bt_trace_class *bt_stream_class_borrow_trace_class( - bt_stream_class *stream_class); + bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -694,7 +694,7 @@ extern bt_trace_class *bt_stream_class_borrow_trace_class( See bt_stream_class_borrow_trace_class(). */ extern const bt_trace_class *bt_stream_class_borrow_trace_class_const( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @} */ @@ -717,7 +717,7 @@ extern const bt_trace_class *bt_stream_class_borrow_trace_class_const( @bt_pre_not_null{stream_class} */ extern uint64_t bt_stream_class_get_event_class_count( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -752,7 +752,7 @@ extern uint64_t bt_stream_class_get_event_class_count( */ extern bt_event_class * bt_stream_class_borrow_event_class_by_index( - bt_stream_class *stream_class, uint64_t index); + bt_stream_class *stream_class, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -763,7 +763,8 @@ See bt_stream_class_borrow_event_class_by_index(). */ extern const bt_event_class * bt_stream_class_borrow_event_class_by_index_const( - const bt_stream_class *stream_class, uint64_t index); + const bt_stream_class *stream_class, uint64_t index) + __BT_NOEXCEPT; /*! @brief @@ -796,7 +797,7 @@ If there's no event class having the numeric ID \bt_p{id} in */ extern bt_event_class * bt_stream_class_borrow_event_class_by_id( - bt_stream_class *stream_class, uint64_t id); + bt_stream_class *stream_class, uint64_t id) __BT_NOEXCEPT; /*! @brief @@ -807,7 +808,7 @@ See bt_stream_class_borrow_event_class_by_id(). */ extern const bt_event_class * bt_stream_class_borrow_event_class_by_id_const( - const bt_stream_class *stream_class, uint64_t id); + const bt_stream_class *stream_class, uint64_t id) __BT_NOEXCEPT; /*! @} */ @@ -835,7 +836,7 @@ See the \ref api-tir-stream-cls-prop-id "numeric ID" property. trace class. */ extern uint64_t bt_stream_class_get_id( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -880,7 +881,7 @@ See the \ref api-tir-stream-cls-prop-name "name" property. Returns the name of a stream class. */ extern bt_stream_class_set_name_status bt_stream_class_set_name( - bt_stream_class *stream_class, const char *name); + bt_stream_class *stream_class, const char *name) __BT_NOEXCEPT; /*! @brief @@ -907,7 +908,7 @@ If \bt_p{stream_class} has no name, this function returns \c NULL. Sets the name of a stream class. */ extern const char *bt_stream_class_get_name( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -950,7 +951,7 @@ property. extern bt_stream_class_set_default_clock_class_status bt_stream_class_set_default_clock_class( bt_stream_class *stream_class, - bt_clock_class *clock_class); + bt_clock_class *clock_class) __BT_NOEXCEPT; /*! @brief @@ -978,7 +979,7 @@ returns \c NULL. \c const version of this function. */ extern bt_clock_class *bt_stream_class_borrow_default_clock_class( - bt_stream_class *stream_class); + bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -989,7 +990,7 @@ See bt_stream_class_borrow_default_clock_class(). */ extern const bt_clock_class * bt_stream_class_borrow_default_clock_class_const( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1064,7 +1065,7 @@ bt_stream_class_set_supports_packets()). extern bt_stream_class_set_field_class_status bt_stream_class_set_packet_context_field_class( bt_stream_class *stream_class, - bt_field_class *field_class); + bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief @@ -1093,7 +1094,7 @@ returns \c NULL. */ extern bt_field_class * bt_stream_class_borrow_packet_context_field_class( - bt_stream_class *stream_class); + bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1104,7 +1105,7 @@ See bt_stream_class_borrow_packet_context_field_class(). */ extern const bt_field_class * bt_stream_class_borrow_packet_context_field_class_const( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1149,7 +1150,7 @@ property. extern bt_stream_class_set_field_class_status bt_stream_class_set_event_common_context_field_class( bt_stream_class *stream_class, - bt_field_class *field_class); + bt_field_class *field_class) __BT_NOEXCEPT; /*! @brief @@ -1180,7 +1181,7 @@ function returns \c NULL. extern bt_field_class * bt_stream_class_borrow_event_common_context_field_class( - bt_stream_class *stream_class); + bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1191,7 +1192,7 @@ See bt_stream_class_borrow_event_common_context_field_class(). */ extern const bt_field_class * bt_stream_class_borrow_event_common_context_field_class_const( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1218,7 +1219,7 @@ property. */ extern void bt_stream_class_set_assigns_automatic_event_class_id( bt_stream_class *stream_class, - bt_bool assigns_automatic_event_class_id); + bt_bool assigns_automatic_event_class_id) __BT_NOEXCEPT; /*! @brief @@ -1244,7 +1245,7 @@ property. event class IDs. */ extern bt_bool bt_stream_class_assigns_automatic_event_class_id( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1270,7 +1271,8 @@ property. stream IDs. */ extern void bt_stream_class_set_assigns_automatic_stream_id( - bt_stream_class *stream_class, bt_bool assigns_automatic_stream_id); + bt_stream_class *stream_class, + bt_bool assigns_automatic_stream_id) __BT_NOEXCEPT; /*! @brief @@ -1295,7 +1297,7 @@ property. stream IDs. */ extern bt_bool bt_stream_class_assigns_automatic_stream_id( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1351,7 +1353,7 @@ properties. extern void bt_stream_class_set_supports_packets( bt_stream_class *stream_class, bt_bool supports_packets, bt_bool with_beginning_default_clock_snapshot, - bt_bool with_end_default_clock_snapshot); + bt_bool with_end_default_clock_snapshot) __BT_NOEXCEPT; /*! @brief @@ -1374,7 +1376,7 @@ property. Sets whether or not a stream class's streams have packets. */ extern bt_bool bt_stream_class_supports_packets( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1403,7 +1405,7 @@ property. have an end default clock snapshot. */ extern bt_bool bt_stream_class_packets_have_beginning_default_clock_snapshot( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1432,7 +1434,7 @@ property. have a beginning default clock snapshot. */ extern bt_bool bt_stream_class_packets_have_end_default_clock_snapshot( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1478,7 +1480,7 @@ properties. extern void bt_stream_class_set_supports_discarded_events( bt_stream_class *stream_class, bt_bool supports_discarded_events, - bt_bool with_default_clock_snapshots); + bt_bool with_default_clock_snapshots) __BT_NOEXCEPT; /*! @brief @@ -1504,7 +1506,7 @@ property. events. */ extern bt_bool bt_stream_class_supports_discarded_events( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1531,7 +1533,7 @@ property. events. */ extern bt_bool bt_stream_class_discarded_events_have_default_clock_snapshots( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1583,7 +1585,7 @@ bt_stream_class_set_supports_packets()). extern void bt_stream_class_set_supports_discarded_packets( bt_stream_class *stream_class, bt_bool supports_discarded_packets, - bt_bool with_default_clock_snapshots); + bt_bool with_default_clock_snapshots) __BT_NOEXCEPT; /*! @brief @@ -1609,7 +1611,7 @@ property. packets. */ extern bt_bool bt_stream_class_supports_discarded_packets( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1636,7 +1638,7 @@ property. packets. */ extern bt_bool bt_stream_class_discarded_packets_have_default_clock_snapshots( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1668,7 +1670,8 @@ property. Borrows the user attributes of a stream class. */ extern void bt_stream_class_set_user_attributes( - bt_stream_class *stream_class, const bt_value *user_attributes); + bt_stream_class *stream_class, + const bt_value *user_attributes) __BT_NOEXCEPT; /*! @brief @@ -1696,7 +1699,7 @@ property. \c const version of this function. */ extern bt_value *bt_stream_class_borrow_user_attributes( - bt_stream_class *stream_class); + bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1706,7 +1709,7 @@ extern bt_value *bt_stream_class_borrow_user_attributes( See bt_stream_class_borrow_user_attributes(). */ extern const bt_value *bt_stream_class_borrow_user_attributes_const( - const bt_stream_class *stream_class); + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @} */ @@ -1730,7 +1733,8 @@ extern const bt_value *bt_stream_class_borrow_user_attributes_const( @sa bt_stream_class_put_ref() — Decrements the reference count of a stream class. */ -extern void bt_stream_class_get_ref(const bt_stream_class *stream_class); +extern void bt_stream_class_get_ref( + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief @@ -1747,7 +1751,8 @@ extern void bt_stream_class_get_ref(const bt_stream_class *stream_class); @sa bt_stream_class_get_ref() — Increments the reference count of a stream class. */ -extern void bt_stream_class_put_ref(const bt_stream_class *stream_class); +extern void bt_stream_class_put_ref( + const bt_stream_class *stream_class) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/trace-ir/stream.h b/include/babeltrace2/trace-ir/stream.h index 1695c96f..70628359 100644 --- a/include/babeltrace2/trace-ir/stream.h +++ b/include/babeltrace2/trace-ir/stream.h @@ -243,7 +243,7 @@ On success, the returned stream has the following property values: trace. */ extern bt_stream *bt_stream_create(bt_stream_class *stream_class, - bt_trace *trace); + bt_trace *trace) __BT_NOEXCEPT; /*! @brief @@ -311,7 +311,7 @@ On success, the returned stream has the following property values: */ extern bt_stream *bt_stream_create_with_id( bt_stream_class *stream_class, - bt_trace *trace, uint64_t id); + bt_trace *trace, uint64_t id) __BT_NOEXCEPT; /*! @} */ @@ -336,7 +336,7 @@ extern bt_stream *bt_stream_create_with_id( @sa bt_stream_borrow_class_const() — \c const version of this function. */ -extern bt_stream_class *bt_stream_borrow_class(bt_stream *stream); +extern bt_stream_class *bt_stream_borrow_class(bt_stream *stream) __BT_NOEXCEPT; /*! @brief @@ -346,7 +346,7 @@ extern bt_stream_class *bt_stream_borrow_class(bt_stream *stream); See bt_stream_borrow_class(). */ extern const bt_stream_class *bt_stream_borrow_class_const( - const bt_stream *stream); + const bt_stream *stream) __BT_NOEXCEPT; /*! @} */ @@ -370,7 +370,7 @@ extern const bt_stream_class *bt_stream_borrow_class_const( @sa bt_stream_borrow_trace_const() — \c const version of this function. */ -extern bt_trace *bt_stream_borrow_trace(bt_stream *stream); +extern bt_trace *bt_stream_borrow_trace(bt_stream *stream) __BT_NOEXCEPT; /*! @brief @@ -380,7 +380,7 @@ extern bt_trace *bt_stream_borrow_trace(bt_stream *stream); See bt_stream_borrow_trace(). */ extern const bt_trace *bt_stream_borrow_trace_const( - const bt_stream *stream); + const bt_stream *stream) __BT_NOEXCEPT; /*! @} */ @@ -407,7 +407,7 @@ See the \ref api-tir-stream-prop-id "numeric ID" property. Creates a stream with a specific numeric ID and adds it to a trace. */ -extern uint64_t bt_stream_get_id(const bt_stream *stream); +extern uint64_t bt_stream_get_id(const bt_stream *stream) __BT_NOEXCEPT; /*! @brief @@ -452,7 +452,7 @@ See the \ref api-tir-stream-prop-name "name" property. Returns the name of a stream. */ extern bt_stream_set_name_status bt_stream_set_name(bt_stream *stream, - const char *name); + const char *name) __BT_NOEXCEPT; /*! @brief @@ -478,7 +478,7 @@ If \bt_p{stream} has no name, this function returns \c NULL. @sa bt_stream_class_set_name() — Sets the name of a stream. */ -extern const char *bt_stream_get_name(const bt_stream *stream); +extern const char *bt_stream_get_name(const bt_stream *stream) __BT_NOEXCEPT; /*! @brief @@ -510,7 +510,8 @@ property. Borrows the user attributes of a stream. */ extern void bt_stream_set_user_attributes( - bt_stream *stream, const bt_value *user_attributes); + bt_stream *stream, const bt_value *user_attributes) + __BT_NOEXCEPT; /*! @brief @@ -537,7 +538,8 @@ property. @sa bt_stream_borrow_user_attributes_const() — \c const version of this function. */ -extern bt_value *bt_stream_borrow_user_attributes(bt_stream *stream); +extern bt_value *bt_stream_borrow_user_attributes(bt_stream *stream) + __BT_NOEXCEPT; /*! @brief @@ -547,7 +549,7 @@ extern bt_value *bt_stream_borrow_user_attributes(bt_stream *stream); See bt_stream_borrow_user_attributes(). */ extern const bt_value *bt_stream_borrow_user_attributes_const( - const bt_stream *stream); + const bt_stream *stream) __BT_NOEXCEPT; /*! @} */ @@ -571,7 +573,7 @@ extern const bt_value *bt_stream_borrow_user_attributes_const( @sa bt_stream_put_ref() — Decrements the reference count of a stream. */ -extern void bt_stream_get_ref(const bt_stream *stream); +extern void bt_stream_get_ref(const bt_stream *stream) __BT_NOEXCEPT; /*! @brief @@ -588,7 +590,7 @@ extern void bt_stream_get_ref(const bt_stream *stream); @sa bt_stream_get_ref() — Increments the reference count of a stream. */ -extern void bt_stream_put_ref(const bt_stream *stream); +extern void bt_stream_put_ref(const bt_stream *stream) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/trace-ir/trace-class.h b/include/babeltrace2/trace-ir/trace-class.h index 579dd5fe..4a50b311 100644 --- a/include/babeltrace2/trace-ir/trace-class.h +++ b/include/babeltrace2/trace-ir/trace-class.h @@ -166,7 +166,8 @@ On success, the returned trace class has the following property values: @returns New trace class reference, or \c NULL on memory error. */ -extern bt_trace_class *bt_trace_class_create(bt_self_component *self_component); +extern bt_trace_class *bt_trace_class_create(bt_self_component *self_component) + __BT_NOEXCEPT; /*! @} */ @@ -189,7 +190,7 @@ extern bt_trace_class *bt_trace_class_create(bt_self_component *self_component); @bt_pre_not_null{trace_class} */ extern uint64_t bt_trace_class_get_stream_class_count( - const bt_trace_class *trace_class); + const bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @brief @@ -223,7 +224,7 @@ extern uint64_t bt_trace_class_get_stream_class_count( \c const version of this function. */ extern bt_stream_class *bt_trace_class_borrow_stream_class_by_index( - bt_trace_class *trace_class, uint64_t index); + bt_trace_class *trace_class, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -234,7 +235,8 @@ See bt_trace_class_borrow_stream_class_by_index(). */ extern const bt_stream_class * bt_trace_class_borrow_stream_class_by_index_const( - const bt_trace_class *trace_class, uint64_t index); + const bt_trace_class *trace_class, + uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -266,7 +268,7 @@ If there's no stream class having the numeric ID \bt_p{id} in \c const version of this function. */ extern bt_stream_class *bt_trace_class_borrow_stream_class_by_id( - bt_trace_class *trace_class, uint64_t id); + bt_trace_class *trace_class, uint64_t id) __BT_NOEXCEPT; /*! @brief @@ -276,7 +278,7 @@ extern bt_stream_class *bt_trace_class_borrow_stream_class_by_id( See bt_trace_class_borrow_stream_class_by_id(). */ extern const bt_stream_class *bt_trace_class_borrow_stream_class_by_id_const( - const bt_trace_class *trace_class, uint64_t id); + const bt_trace_class *trace_class, uint64_t id) __BT_NOEXCEPT; /*! @} */ @@ -309,7 +311,7 @@ property. */ extern void bt_trace_class_set_assigns_automatic_stream_class_id( bt_trace_class *trace_class, - bt_bool assigns_automatic_stream_class_id); + bt_bool assigns_automatic_stream_class_id) __BT_NOEXCEPT; /*! @brief @@ -335,7 +337,7 @@ property. stream class IDs. */ extern bt_bool bt_trace_class_assigns_automatic_stream_class_id( - const bt_trace_class *trace_class); + const bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @brief @@ -367,7 +369,8 @@ property. Borrows the user attributes of a trace class. */ extern void bt_trace_class_set_user_attributes( - bt_trace_class *trace_class, const bt_value *user_attributes); + bt_trace_class *trace_class, + const bt_value *user_attributes) __BT_NOEXCEPT; /*! @brief @@ -395,7 +398,7 @@ property. \c const version of this function. */ extern bt_value *bt_trace_class_borrow_user_attributes( - bt_trace_class *trace_class); + bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @brief @@ -405,7 +408,7 @@ extern bt_value *bt_trace_class_borrow_user_attributes( See bt_trace_class_borrow_user_attributes(). */ extern const bt_value *bt_trace_class_borrow_user_attributes_const( - const bt_trace_class *trace_class); + const bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @} */ @@ -498,7 +501,7 @@ extern bt_trace_class_add_listener_status bt_trace_class_add_destruction_listener( const bt_trace_class *trace_class, bt_trace_class_destruction_listener_func user_func, - void *user_data, bt_listener_id *listener_id); + void *user_data, bt_listener_id *listener_id) __BT_NOEXCEPT; /*! @brief @@ -550,7 +553,8 @@ You can call this function when \bt_p{trace_class} is */ extern bt_trace_class_remove_listener_status bt_trace_class_remove_destruction_listener( - const bt_trace_class *trace_class, bt_listener_id listener_id); + const bt_trace_class *trace_class, bt_listener_id listener_id) + __BT_NOEXCEPT; /*! @} */ @@ -574,7 +578,8 @@ bt_trace_class_remove_destruction_listener( @sa bt_trace_class_put_ref() — Decrements the reference count of a trace class. */ -extern void bt_trace_class_get_ref(const bt_trace_class *trace_class); +extern void bt_trace_class_get_ref( + const bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @brief @@ -591,7 +596,8 @@ extern void bt_trace_class_get_ref(const bt_trace_class *trace_class); @sa bt_trace_class_get_ref() — Increments the reference count of a trace class. */ -extern void bt_trace_class_put_ref(const bt_trace_class *trace_class); +extern void bt_trace_class_put_ref( + const bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/trace-ir/trace.h b/include/babeltrace2/trace-ir/trace.h index 811936fd..954a4387 100644 --- a/include/babeltrace2/trace-ir/trace.h +++ b/include/babeltrace2/trace-ir/trace.h @@ -188,7 +188,7 @@ On success, the returned trace has the following property values: @returns New trace reference, or \c NULL on memory error. */ -extern bt_trace *bt_trace_create(bt_trace_class *trace_class); +extern bt_trace *bt_trace_create(bt_trace_class *trace_class) __BT_NOEXCEPT; /*! @} */ @@ -213,7 +213,7 @@ extern bt_trace *bt_trace_create(bt_trace_class *trace_class); @sa bt_trace_borrow_class_const() — \c const version of this function. */ -extern bt_trace_class *bt_trace_borrow_class(bt_trace *trace); +extern bt_trace_class *bt_trace_borrow_class(bt_trace *trace) __BT_NOEXCEPT; /*! @brief @@ -223,7 +223,7 @@ extern bt_trace_class *bt_trace_borrow_class(bt_trace *trace); See bt_trace_borrow_class(). */ extern const bt_trace_class *bt_trace_borrow_class_const( - const bt_trace *trace); + const bt_trace *trace) __BT_NOEXCEPT; /*! @} */ @@ -245,7 +245,7 @@ extern const bt_trace_class *bt_trace_borrow_class_const( @bt_pre_not_null{trace} */ -extern uint64_t bt_trace_get_stream_count(const bt_trace *trace); +extern uint64_t bt_trace_get_stream_count(const bt_trace *trace) __BT_NOEXCEPT; /*! @brief @@ -279,7 +279,7 @@ extern uint64_t bt_trace_get_stream_count(const bt_trace *trace); \c const version of this function. */ extern bt_stream *bt_trace_borrow_stream_by_index(bt_trace *trace, - uint64_t index); + uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -289,7 +289,7 @@ extern bt_stream *bt_trace_borrow_stream_by_index(bt_trace *trace, See bt_trace_borrow_stream_by_index(). */ extern const bt_stream *bt_trace_borrow_stream_by_index_const( - const bt_trace *trace, uint64_t index); + const bt_trace *trace, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -321,7 +321,7 @@ If there's no stream having the numeric ID \bt_p{id} in \c const version of this function. */ extern bt_stream *bt_trace_borrow_stream_by_id(bt_trace *trace, - uint64_t id); + uint64_t id) __BT_NOEXCEPT; /*! @brief @@ -331,7 +331,7 @@ extern bt_stream *bt_trace_borrow_stream_by_id(bt_trace *trace, See bt_trace_borrow_stream_by_id(). */ extern const bt_stream *bt_trace_borrow_stream_by_id_const( - const bt_trace *trace, uint64_t id); + const bt_trace *trace, uint64_t id) __BT_NOEXCEPT; /*! @} */ @@ -382,7 +382,7 @@ See the \ref api-tir-trace-prop-name "name" property. Returns the name of a trace. */ extern bt_trace_set_name_status bt_trace_set_name(bt_trace *trace, - const char *name); + const char *name) __BT_NOEXCEPT; /*! @brief @@ -408,7 +408,7 @@ If \bt_p{trace} has no name, this function returns \c NULL. @sa bt_trace_set_name() — Sets the name of a trace. */ -extern const char *bt_trace_get_name(const bt_trace *trace); +extern const char *bt_trace_get_name(const bt_trace *trace) __BT_NOEXCEPT; /*! @brief @@ -430,7 +430,7 @@ See the \ref api-tir-trace-prop-uuid "UUID" property. @sa bt_trace_get_uuid() — Returns the UUID of a trace. */ -extern void bt_trace_set_uuid(bt_trace *trace, bt_uuid uuid); +extern void bt_trace_set_uuid(bt_trace *trace, bt_uuid uuid) __BT_NOEXCEPT; /*! @brief @@ -456,7 +456,7 @@ If \bt_p{trace} has no UUID, this function returns \c NULL. @sa bt_trace_set_uuid() — Sets the UUID of a trace. */ -extern bt_uuid bt_trace_get_uuid(const bt_trace *trace); +extern bt_uuid bt_trace_get_uuid(const bt_trace *trace) __BT_NOEXCEPT; /*! @brief @@ -509,7 +509,7 @@ On success, if \bt_p{trace} already contains an environment entry named */ extern bt_trace_set_environment_entry_status bt_trace_set_environment_entry_integer(bt_trace *trace, const char *name, - int64_t value); + int64_t value) __BT_NOEXCEPT; /*! @brief @@ -545,7 +545,7 @@ On success, if \bt_p{trace} already contains an environment entry named */ extern bt_trace_set_environment_entry_status bt_trace_set_environment_entry_string(bt_trace *trace, const char *name, - const char *value); + const char *value) __BT_NOEXCEPT; /*! @brief @@ -562,7 +562,8 @@ See the \ref api-tir-trace-prop-env "environment" property. @bt_pre_not_null{trace} */ -extern uint64_t bt_trace_get_environment_entry_count(const bt_trace *trace); +extern uint64_t bt_trace_get_environment_entry_count( + const bt_trace *trace) __BT_NOEXCEPT; /*! @brief @@ -612,7 +613,7 @@ See the \ref api-tir-trace-prop-env "environment" property. */ extern void bt_trace_borrow_environment_entry_by_index_const( const bt_trace *trace, uint64_t index, - const char **name, const bt_value **value); + const char **name, const bt_value **value) __BT_NOEXCEPT; /*! @brief @@ -647,7 +648,7 @@ function returns \c NULL. @bt_pre_not_null{name} */ extern const bt_value *bt_trace_borrow_environment_entry_value_by_name_const( - const bt_trace *trace, const char *name); + const bt_trace *trace, const char *name) __BT_NOEXCEPT; /*! @brief @@ -677,7 +678,7 @@ property. Borrows the user attributes of a trace. */ extern void bt_trace_set_user_attributes( - bt_trace *trace, const bt_value *user_attributes); + bt_trace *trace, const bt_value *user_attributes) __BT_NOEXCEPT; /*! @brief @@ -703,7 +704,7 @@ property. @sa bt_trace_borrow_user_attributes_const() — \c const version of this function. */ -extern bt_value *bt_trace_borrow_user_attributes(bt_trace *trace); +extern bt_value *bt_trace_borrow_user_attributes(bt_trace *trace) __BT_NOEXCEPT; /*! @brief @@ -713,7 +714,7 @@ extern bt_value *bt_trace_borrow_user_attributes(bt_trace *trace); See bt_trace_borrow_user_attributes(). */ extern const bt_value *bt_trace_borrow_user_attributes_const( - const bt_trace *trace); + const bt_trace *trace) __BT_NOEXCEPT; /*! @} */ @@ -804,7 +805,7 @@ added destruction listener with bt_trace_remove_destruction_listener(). extern bt_trace_add_listener_status bt_trace_add_destruction_listener( const bt_trace *trace, bt_trace_destruction_listener_func user_func, - void *user_data, bt_listener_id *listener_id); + void *user_data, bt_listener_id *listener_id) __BT_NOEXCEPT; /*! @brief @@ -855,7 +856,8 @@ You can call this function when \bt_p{trace} is Adds a destruction listener to a trace. */ extern bt_trace_remove_listener_status bt_trace_remove_destruction_listener( - const bt_trace *trace, bt_listener_id listener_id); + const bt_trace *trace, bt_listener_id listener_id) + __BT_NOEXCEPT; /*! @} */ @@ -879,7 +881,7 @@ extern bt_trace_remove_listener_status bt_trace_remove_destruction_listener( @sa bt_trace_put_ref() — Decrements the reference count of a trace. */ -extern void bt_trace_get_ref(const bt_trace *trace); +extern void bt_trace_get_ref(const bt_trace *trace) __BT_NOEXCEPT; /*! @brief @@ -896,7 +898,7 @@ extern void bt_trace_get_ref(const bt_trace *trace); @sa bt_trace_get_ref() — Increments the reference count of a trace. */ -extern void bt_trace_put_ref(const bt_trace *trace); +extern void bt_trace_put_ref(const bt_trace *trace) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/util.h b/include/babeltrace2/util.h index adece55d..80c0e66b 100644 --- a/include/babeltrace2/util.h +++ b/include/babeltrace2/util.h @@ -123,7 +123,7 @@ code if any step of the computation process causes an integer overflow. bt_util_clock_cycles_to_ns_from_origin_status bt_util_clock_cycles_to_ns_from_origin(uint64_t cycles, uint64_t frequency, int64_t offset_seconds, - uint64_t offset_cycles, int64_t *ns_from_origin); + uint64_t offset_cycles, int64_t *ns_from_origin) __BT_NOEXCEPT; /*! @} */ diff --git a/include/babeltrace2/value.h b/include/babeltrace2/value.h index ac95bafc..f6bdbee4 100644 --- a/include/babeltrace2/value.h +++ b/include/babeltrace2/value.h @@ -325,7 +325,7 @@ typedef enum bt_value_type { @sa bt_value_is_map() — Returns whether or not a value is a map value. */ -extern bt_value_type bt_value_get_type(const bt_value *value); +extern bt_value_type bt_value_get_type(const bt_value *value) __BT_NOEXCEPT; /*! @brief @@ -370,7 +370,7 @@ returns #BT_TRUE. */ static inline bt_bool bt_value_type_is(const bt_value_type type, - const bt_value_type other_type) + const bt_value_type other_type) __BT_NOEXCEPT { return (type & other_type) == other_type; } @@ -401,7 +401,7 @@ bt_bool bt_value_type_is(const bt_value_type type, The null value singleton. */ static inline -bt_bool bt_value_is_null(const bt_value *value) +bt_bool bt_value_is_null(const bt_value *value) __BT_NOEXCEPT { return bt_value_get_type(value) == BT_VALUE_TYPE_NULL; } @@ -425,7 +425,7 @@ bt_bool bt_value_is_null(const bt_value *value) type. */ static inline -bt_bool bt_value_is_bool(const bt_value *value) +bt_bool bt_value_is_bool(const bt_value *value) __BT_NOEXCEPT { return bt_value_get_type(value) == BT_VALUE_TYPE_BOOL; } @@ -450,7 +450,7 @@ bt_bool bt_value_is_bool(const bt_value *value) type. */ static inline -bt_bool bt_value_is_unsigned_integer(const bt_value *value) +bt_bool bt_value_is_unsigned_integer(const bt_value *value) __BT_NOEXCEPT { return bt_value_get_type(value) == BT_VALUE_TYPE_UNSIGNED_INTEGER; } @@ -475,7 +475,7 @@ bt_bool bt_value_is_unsigned_integer(const bt_value *value) type. */ static inline -bt_bool bt_value_is_signed_integer(const bt_value *value) +bt_bool bt_value_is_signed_integer(const bt_value *value) __BT_NOEXCEPT { return bt_value_get_type(value) == BT_VALUE_TYPE_SIGNED_INTEGER; } @@ -499,7 +499,7 @@ bt_bool bt_value_is_signed_integer(const bt_value *value) type. */ static inline -bt_bool bt_value_is_real(const bt_value *value) +bt_bool bt_value_is_real(const bt_value *value) __BT_NOEXCEPT { return bt_value_get_type(value) == BT_VALUE_TYPE_REAL; } @@ -523,7 +523,7 @@ bt_bool bt_value_is_real(const bt_value *value) type. */ static inline -bt_bool bt_value_is_string(const bt_value *value) +bt_bool bt_value_is_string(const bt_value *value) __BT_NOEXCEPT { return bt_value_get_type(value) == BT_VALUE_TYPE_STRING; } @@ -547,7 +547,7 @@ bt_bool bt_value_is_string(const bt_value *value) type. */ static inline -bt_bool bt_value_is_array(const bt_value *value) +bt_bool bt_value_is_array(const bt_value *value) __BT_NOEXCEPT { return bt_value_get_type(value) == BT_VALUE_TYPE_ARRAY; } @@ -571,7 +571,7 @@ bt_bool bt_value_is_array(const bt_value *value) type. */ static inline -bt_bool bt_value_is_map(const bt_value *value) +bt_bool bt_value_is_map(const bt_value *value) __BT_NOEXCEPT { return bt_value_get_type(value) == BT_VALUE_TYPE_MAP; } @@ -633,7 +633,7 @@ The returned value has the type #BT_VALUE_TYPE_BOOL. @sa bt_value_bool_create_init() — Creates a boolean value with a given initial raw value. */ -extern bt_value *bt_value_bool_create(void); +extern bt_value *bt_value_bool_create(void) __BT_NOEXCEPT; /*! @brief @@ -650,7 +650,7 @@ The returned value has the type #BT_VALUE_TYPE_BOOL. @sa bt_value_bool_create() — Creates a boolean value initialized to #BT_FALSE. */ -extern bt_value *bt_value_bool_create_init(bt_bool raw_value); +extern bt_value *bt_value_bool_create_init(bt_bool raw_value) __BT_NOEXCEPT; /*! @brief @@ -669,7 +669,7 @@ extern bt_value *bt_value_bool_create_init(bt_bool raw_value); @sa bt_value_bool_get() — Returns the raw value of a boolean value. */ -extern void bt_value_bool_set(bt_value *value, bt_bool raw_value); +extern void bt_value_bool_set(bt_value *value, bt_bool raw_value) __BT_NOEXCEPT; /*! @brief @@ -687,7 +687,7 @@ extern void bt_value_bool_set(bt_value *value, bt_bool raw_value); @sa bt_value_bool_set() — Sets the raw value of a boolean value. */ -extern bt_bool bt_value_bool_get(const bt_value *value); +extern bt_bool bt_value_bool_get(const bt_value *value) __BT_NOEXCEPT; /*! @} */ @@ -708,7 +708,7 @@ The returned value has the type #BT_VALUE_TYPE_UNSIGNED_INTEGER. @sa bt_value_integer_unsigned_create_init() — Creates an unsigned integer value with a given initial raw value. */ -extern bt_value *bt_value_integer_unsigned_create(void); +extern bt_value *bt_value_integer_unsigned_create(void) __BT_NOEXCEPT; /*! @brief @@ -726,7 +726,7 @@ The returned value has the type #BT_VALUE_TYPE_UNSIGNED_INTEGER. @sa bt_value_bool_create() — Creates an unsigned integer value initialized to 0. */ -extern bt_value *bt_value_integer_unsigned_create_init(uint64_t raw_value); +extern bt_value *bt_value_integer_unsigned_create_init(uint64_t raw_value) __BT_NOEXCEPT; /*! @brief @@ -747,7 +747,7 @@ extern bt_value *bt_value_integer_unsigned_create_init(uint64_t raw_value); Returns the raw value of an unsigned integer value. */ extern void bt_value_integer_unsigned_set(bt_value *value, - uint64_t raw_value); + uint64_t raw_value) __BT_NOEXCEPT; /*! @brief @@ -765,7 +765,7 @@ extern void bt_value_integer_unsigned_set(bt_value *value, @sa bt_value_integer_unsigned_set() — Sets the raw value of an unsigned integer value. */ -extern uint64_t bt_value_integer_unsigned_get(const bt_value *value); +extern uint64_t bt_value_integer_unsigned_get(const bt_value *value) __BT_NOEXCEPT; /*! @} */ @@ -786,7 +786,7 @@ The returned value has the type #BT_VALUE_TYPE_SIGNED_INTEGER. @sa bt_value_integer_signed_create_init() — Creates a signed integer value with a given initial raw value. */ -extern bt_value *bt_value_integer_signed_create(void); +extern bt_value *bt_value_integer_signed_create(void) __BT_NOEXCEPT; /*! @brief @@ -804,7 +804,7 @@ The returned value has the type #BT_VALUE_TYPE_SIGNED_INTEGER. @sa bt_value_bool_create() — Creates a signed integer value initialized to 0. */ -extern bt_value *bt_value_integer_signed_create_init(int64_t raw_value); +extern bt_value *bt_value_integer_signed_create_init(int64_t raw_value) __BT_NOEXCEPT; /*! @brief @@ -824,7 +824,7 @@ extern bt_value *bt_value_integer_signed_create_init(int64_t raw_value); @sa bt_value_integer_signed_get() — Returns the raw value of a signed integer value. */ -extern void bt_value_integer_signed_set(bt_value *value, int64_t raw_value); +extern void bt_value_integer_signed_set(bt_value *value, int64_t raw_value) __BT_NOEXCEPT; /*! @brief @@ -842,7 +842,7 @@ extern void bt_value_integer_signed_set(bt_value *value, int64_t raw_value); @sa bt_value_integer_signed_set() — Sets the raw value of a signed integer value. */ -extern int64_t bt_value_integer_signed_get(const bt_value *value); +extern int64_t bt_value_integer_signed_get(const bt_value *value) __BT_NOEXCEPT; /*! @} */ @@ -863,7 +863,7 @@ The returned value has the type #BT_VALUE_TYPE_REAL. @sa bt_value_real_create_init() — Creates a real value with a given initial raw value. */ -extern bt_value *bt_value_real_create(void); +extern bt_value *bt_value_real_create(void) __BT_NOEXCEPT; /*! @brief @@ -880,7 +880,7 @@ The returned value has the type #BT_VALUE_TYPE_REAL. @sa bt_value_real_create() — Creates a real value initialized to 0. */ -extern bt_value *bt_value_real_create_init(double raw_value); +extern bt_value *bt_value_real_create_init(double raw_value) __BT_NOEXCEPT; /*! @brief @@ -899,7 +899,7 @@ extern bt_value *bt_value_real_create_init(double raw_value); @sa bt_value_real_get() — Returns the raw value of a real value. */ -extern void bt_value_real_set(bt_value *value, double raw_value); +extern void bt_value_real_set(bt_value *value, double raw_value) __BT_NOEXCEPT; /*! @brief @@ -917,7 +917,7 @@ extern void bt_value_real_set(bt_value *value, double raw_value); @sa bt_value_real_set() — Sets the raw value of a real value. */ -extern double bt_value_real_get(const bt_value *value); +extern double bt_value_real_get(const bt_value *value) __BT_NOEXCEPT; /*! @} */ @@ -938,7 +938,7 @@ The returned value has the type #BT_VALUE_TYPE_STRING. @sa bt_value_string_create_init() — Creates a string value with a given initial raw value. */ -extern bt_value *bt_value_string_create(void); +extern bt_value *bt_value_string_create(void) __BT_NOEXCEPT; /*! @brief @@ -958,7 +958,7 @@ The returned value has the type #BT_VALUE_TYPE_STRING. @sa bt_value_string_create() — Creates an empty string value. */ -extern bt_value *bt_value_string_create_init(const char *raw_value); +extern bt_value *bt_value_string_create_init(const char *raw_value) __BT_NOEXCEPT; /*! @brief @@ -1003,7 +1003,7 @@ typedef enum bt_value_string_set_status { Returns the raw value of a string value. */ extern bt_value_string_set_status bt_value_string_set(bt_value *value, - const char *raw_value); + const char *raw_value) __BT_NOEXCEPT; /*! @brief @@ -1025,7 +1025,7 @@ extern bt_value_string_set_status bt_value_string_set(bt_value *value, @sa bt_value_string_set() — Sets the raw value of a string value. */ -extern const char *bt_value_string_get(const bt_value *value); +extern const char *bt_value_string_get(const bt_value *value) __BT_NOEXCEPT; /*! @} */ @@ -1043,7 +1043,7 @@ The returned value has the type #BT_VALUE_TYPE_ARRAY. @returns New array value reference, or \c NULL on memory error. */ -extern bt_value *bt_value_array_create(void); +extern bt_value *bt_value_array_create(void) __BT_NOEXCEPT; /*! @brief @@ -1107,7 +1107,7 @@ To append a null value, pass #bt_value_null as \bt_p{element_value}. Creates and appends an empty map value to an array value. */ extern bt_value_array_append_element_status bt_value_array_append_element( - bt_value *value, bt_value *element_value); + bt_value *value, bt_value *element_value) __BT_NOEXCEPT; /*! @brief @@ -1136,7 +1136,7 @@ extern bt_value_array_append_element_status bt_value_array_append_element( Appends an existing value to an array value. */ extern bt_value_array_append_element_status -bt_value_array_append_bool_element(bt_value *value, bt_bool raw_value); +bt_value_array_append_bool_element(bt_value *value, bt_bool raw_value) __BT_NOEXCEPT; /*! @brief @@ -1167,7 +1167,7 @@ bt_value_array_append_bool_element(bt_value *value, bt_bool raw_value); */ extern bt_value_array_append_element_status bt_value_array_append_unsigned_integer_element(bt_value *value, - uint64_t raw_value); + uint64_t raw_value) __BT_NOEXCEPT; /*! @brief @@ -1198,7 +1198,7 @@ bt_value_array_append_unsigned_integer_element(bt_value *value, */ extern bt_value_array_append_element_status bt_value_array_append_signed_integer_element(bt_value *value, - int64_t raw_value); + int64_t raw_value) __BT_NOEXCEPT; /*! @brief @@ -1227,7 +1227,7 @@ bt_value_array_append_signed_integer_element(bt_value *value, Appends an existing value to an array value. */ extern bt_value_array_append_element_status -bt_value_array_append_real_element(bt_value *value, double raw_value); +bt_value_array_append_real_element(bt_value *value, double raw_value) __BT_NOEXCEPT; /*! @brief @@ -1257,7 +1257,7 @@ bt_value_array_append_real_element(bt_value *value, double raw_value); Appends an existing value to an array value. */ extern bt_value_array_append_element_status -bt_value_array_append_string_element(bt_value *value, const char *raw_value); +bt_value_array_append_string_element(bt_value *value, const char *raw_value) __BT_NOEXCEPT; /*! @brief @@ -1292,7 +1292,7 @@ array value. */ extern bt_value_array_append_element_status bt_value_array_append_empty_array_element(bt_value *value, - bt_value **element_value); + bt_value **element_value) __BT_NOEXCEPT; /*! @brief @@ -1327,7 +1327,7 @@ map value. */ extern bt_value_array_append_element_status bt_value_array_append_empty_map_element(bt_value *value, - bt_value **element_value); + bt_value **element_value) __BT_NOEXCEPT; /*! @brief @@ -1386,7 +1386,7 @@ at index \bt_p{index}. */ extern bt_value_array_set_element_by_index_status bt_value_array_set_element_by_index(bt_value *value, uint64_t index, - bt_value *element_value); + bt_value *element_value) __BT_NOEXCEPT; /*! @brief @@ -1416,7 +1416,7 @@ bt_value_array_set_element_by_index(bt_value *value, uint64_t index, \c const version of this function. */ extern bt_value *bt_value_array_borrow_element_by_index(bt_value *value, - uint64_t index); + uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -1426,7 +1426,7 @@ extern bt_value *bt_value_array_borrow_element_by_index(bt_value *value, See bt_value_array_borrow_element_by_index(). */ extern const bt_value *bt_value_array_borrow_element_by_index_const( - const bt_value *value, uint64_t index); + const bt_value *value, uint64_t index) __BT_NOEXCEPT; /*! @brief @@ -1444,7 +1444,7 @@ extern const bt_value *bt_value_array_borrow_element_by_index_const( @sa bt_value_array_is_empty() — Returns whether or not an array value is empty. */ -extern uint64_t bt_value_array_get_length(const bt_value *value); +extern uint64_t bt_value_array_get_length(const bt_value *value) __BT_NOEXCEPT; /*! @brief @@ -1463,7 +1463,7 @@ extern uint64_t bt_value_array_get_length(const bt_value *value); Returns the length of an array value. */ static inline -bt_bool bt_value_array_is_empty(const bt_value *value) +bt_bool bt_value_array_is_empty(const bt_value *value) __BT_NOEXCEPT { return bt_value_array_get_length(value) == 0; } @@ -1484,7 +1484,7 @@ The returned value has the type #BT_VALUE_TYPE_MAP. @returns New map value reference, or \c NULL on memory error. */ -extern bt_value *bt_value_map_create(void); +extern bt_value *bt_value_map_create(void) __BT_NOEXCEPT; /*! @brief @@ -1558,7 +1558,8 @@ On success, if \bt_p{value} already contains an entry with key Creates a map value and uses it to insert an entry in a map value. */ extern bt_value_map_insert_entry_status bt_value_map_insert_entry( - bt_value *value, const char *key, bt_value *entry_value); + bt_value *value, const char *key, + bt_value *entry_value) __BT_NOEXCEPT; /*! @brief @@ -1592,7 +1593,8 @@ created boolean value. Inserts an entry with an existing value in a map value. */ extern bt_value_map_insert_entry_status bt_value_map_insert_bool_entry( - bt_value *value, const char *key, bt_bool raw_value); + bt_value *value, const char *key, bt_bool raw_value) + __BT_NOEXCEPT; /*! @brief @@ -1627,7 +1629,7 @@ created unsigned integer value. */ extern bt_value_map_insert_entry_status bt_value_map_insert_unsigned_integer_entry(bt_value *value, const char *key, - uint64_t raw_value); + uint64_t raw_value) __BT_NOEXCEPT; /*! @brief @@ -1662,7 +1664,7 @@ created signed integer value. */ extern bt_value_map_insert_entry_status bt_value_map_insert_signed_integer_entry(bt_value *value, const char *key, - int64_t raw_value); + int64_t raw_value) __BT_NOEXCEPT; /*! @brief @@ -1696,7 +1698,8 @@ created real value. Inserts an entry with an existing value in a map value. */ extern bt_value_map_insert_entry_status bt_value_map_insert_real_entry( - bt_value *value, const char *key, double raw_value); + bt_value *value, const char *key, double raw_value) + __BT_NOEXCEPT; /*! @brief @@ -1731,7 +1734,7 @@ created string value. */ extern bt_value_map_insert_entry_status bt_value_map_insert_string_entry(bt_value *value, const char *key, - const char *raw_value); + const char *raw_value) __BT_NOEXCEPT; /*! @brief @@ -1770,7 +1773,7 @@ created empty array value. */ extern bt_value_map_insert_entry_status bt_value_map_insert_empty_array_entry(bt_value *value, const char *key, - bt_value **entry_value); + bt_value **entry_value) __BT_NOEXCEPT; /*! @brief @@ -1809,7 +1812,7 @@ created empty map value. */ extern bt_value_map_insert_entry_status bt_value_map_insert_empty_map_entry(bt_value *value, const char *key, - bt_value **entry_value); + bt_value **entry_value) __BT_NOEXCEPT; /*! @brief @@ -1843,7 +1846,7 @@ returns \c NULL. Returns whether or not a map value has an entry with a given key. */ extern bt_value *bt_value_map_borrow_entry_value( - bt_value *value, const char *key); + bt_value *value, const char *key) __BT_NOEXCEPT; /*! @brief @@ -1853,7 +1856,7 @@ extern bt_value *bt_value_map_borrow_entry_value( See bt_value_map_borrow_entry_value(). */ extern const bt_value *bt_value_map_borrow_entry_value_const( - const bt_value *value, const char *key); + const bt_value *value, const char *key) __BT_NOEXCEPT; /*! @brief @@ -2008,7 +2011,7 @@ The iteration process stops when one of: */ extern bt_value_map_foreach_entry_status bt_value_map_foreach_entry( bt_value *value, bt_value_map_foreach_entry_func user_func, - void *user_data); + void *user_data) __BT_NOEXCEPT; /*! @brief @@ -2123,7 +2126,7 @@ See bt_value_map_foreach_entry(). extern bt_value_map_foreach_entry_const_status bt_value_map_foreach_entry_const( const bt_value *value, bt_value_map_foreach_entry_const_func user_func, - void *user_data); + void *user_data) __BT_NOEXCEPT; /*! @brief @@ -2141,7 +2144,7 @@ extern bt_value_map_foreach_entry_const_status bt_value_map_foreach_entry_const( @sa bt_value_map_is_empty() — Returns whether or not a map value is empty. */ -extern uint64_t bt_value_map_get_size(const bt_value *value); +extern uint64_t bt_value_map_get_size(const bt_value *value) __BT_NOEXCEPT; /*! @brief @@ -2160,7 +2163,7 @@ extern uint64_t bt_value_map_get_size(const bt_value *value); Returns the size of a map value. */ static inline -bt_bool bt_value_map_is_empty(const bt_value *value) +bt_bool bt_value_map_is_empty(const bt_value *value) __BT_NOEXCEPT { return bt_value_map_get_size(value) == 0; } @@ -2186,7 +2189,7 @@ bt_bool bt_value_map_is_empty(const bt_value *value) Borrows the value of a specific map value entry. */ extern bt_bool bt_value_map_has_entry(const bt_value *value, - const char *key); + const char *key) __BT_NOEXCEPT; /*! @brief @@ -2272,7 +2275,7 @@ The map value \bt_p{value} becomes: Deep-copies a value. */ extern bt_value_map_extend_status bt_value_map_extend( - bt_value *value, const bt_value *extension_value); + bt_value *value, const bt_value *extension_value) __BT_NOEXCEPT; /*! @} */ @@ -2325,7 +2328,7 @@ identical. @bt_pre_not_null{copy_value} */ extern bt_value_copy_status bt_value_copy(const bt_value *value, - bt_value **copy_value); + bt_value **copy_value) __BT_NOEXCEPT; /*! @brief @@ -2348,7 +2351,7 @@ extern bt_value_copy_status bt_value_copy(const bt_value *value, @bt_pre_not_null{b_value} */ extern bt_bool bt_value_is_equal(const bt_value *a_value, - const bt_value *b_value); + const bt_value *b_value) __BT_NOEXCEPT; /*! @} */ @@ -2372,7 +2375,7 @@ extern bt_bool bt_value_is_equal(const bt_value *a_value, @sa bt_value_put_ref() — Decrements the reference count of a value. */ -extern void bt_value_get_ref(const bt_value *value); +extern void bt_value_get_ref(const bt_value *value) __BT_NOEXCEPT; /*! @brief @@ -2389,7 +2392,7 @@ extern void bt_value_get_ref(const bt_value *value); @sa bt_value_get_ref() — Increments the reference count of a value. */ -extern void bt_value_put_ref(const bt_value *value); +extern void bt_value_put_ref(const bt_value *value) __BT_NOEXCEPT; /*! @brief diff --git a/include/babeltrace2/version.h b/include/babeltrace2/version.h index c3689eba..66ad5415 100644 --- a/include/babeltrace2/version.h +++ b/include/babeltrace2/version.h @@ -68,7 +68,7 @@ version: @returns Major version of the library. */ -extern unsigned int bt_version_get_major(void); +extern unsigned int bt_version_get_major(void) __BT_NOEXCEPT; /*! @brief @@ -77,7 +77,7 @@ extern unsigned int bt_version_get_major(void); @returns Minor version of the library. */ -extern unsigned int bt_version_get_minor(void); +extern unsigned int bt_version_get_minor(void) __BT_NOEXCEPT; /*! @brief @@ -86,7 +86,7 @@ extern unsigned int bt_version_get_minor(void); @returns Patch version of the library. */ -extern unsigned int bt_version_get_patch(void); +extern unsigned int bt_version_get_patch(void) __BT_NOEXCEPT; /*! @brief @@ -98,7 +98,7 @@ The development stage \em can contain a version suffix such as @returns Development stage of the library's version, or \c NULL if none. */ -extern const char *bt_version_get_development_stage(void); +extern const char *bt_version_get_development_stage(void) __BT_NOEXCEPT; /*! @brief @@ -112,7 +112,7 @@ of the library. Version control system revision's description of the library's version, or \c NULL if none. */ -extern const char *bt_version_get_vcs_revision_description(void); +extern const char *bt_version_get_vcs_revision_description(void) __BT_NOEXCEPT; /*! @brief @@ -127,7 +127,7 @@ development build, this function returns \c NULL. @sa bt_version_get_name_description() — Returns the description of libbabeltrace2's release name. */ -extern const char *bt_version_get_name(void); +extern const char *bt_version_get_name(void) __BT_NOEXCEPT; /*! @brief @@ -142,7 +142,7 @@ case for a development build, this function returns \c NULL. @sa bt_version_get_name() — Returns libbabeltrace2's release name. */ -extern const char *bt_version_get_name_description(void); +extern const char *bt_version_get_name_description(void) __BT_NOEXCEPT; /*! @brief @@ -154,7 +154,7 @@ custom build. @returns Library's version extra name, or \c NULL if not available. */ -extern const char *bt_version_get_extra_name(void); +extern const char *bt_version_get_extra_name(void) __BT_NOEXCEPT; /*! @brief @@ -170,7 +170,7 @@ for a custom build. Can contain newlines. @endparblock */ -extern const char *bt_version_get_extra_description(void); +extern const char *bt_version_get_extra_description(void) __BT_NOEXCEPT; /*! @brief @@ -187,7 +187,7 @@ for a custom build. applied to Babeltrace's source tree for a custom build. @endparblock */ -extern const char *bt_version_get_extra_patch_names(void); +extern const char *bt_version_get_extra_patch_names(void) __BT_NOEXCEPT; /*! @} */ diff --git a/src/bindings/python/bt2/bt2/native_bt.i b/src/bindings/python/bt2/bt2/native_bt.i index 21a869e6..b4b5e904 100644 --- a/src/bindings/python/bt2/bt2/native_bt.i +++ b/src/bindings/python/bt2/bt2/native_bt.i @@ -199,10 +199,11 @@ void bt_bt2_exit_handler(void); #define __BT_IN_BABELTRACE_H /* - * Define `__BT_ATTR_FORMAT_PRINTF` to nothing, otherwise SWIG fails to parse - * the included header files that use it. + * Define `__BT_ATTR_FORMAT_PRINTF` and `__BT_NOEXCEPT` to nothing, + * otherwise SWIG fails to parse the included header files that use it. */ #define __BT_ATTR_FORMAT_PRINTF(_string_index, _first_to_check) +#define __BT_NOEXCEPT /* Common types */ %include