Those comments are very hard to maintain and are pretty much useless.
There are tools to ensure that headers include exactly what they need.
Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Change-Id: Idb7545526426e0a18e6a2fa8af20b9f22ed88407
Reviewed-on: https://review.lttng.org/c/babeltrace/+/1672
Tested-by: jenkins <jenkins@lttng.org>
#include <stdarg.h>
-/*
- * For bt_error, bt_self_component, bt_self_component_class, and
- * bt_self_message_iterator
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
#include <stddef.h>
-/* For bt_error, bt_error_cause */
#include <babeltrace2/types.h>
-
-/* For bt_component_class_type */
#include <babeltrace2/graph/component-class-const.h>
#ifdef __cplusplus
#include <stdint.h>
#include <stddef.h>
-/* For bt_error, bt_error_cause */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_bool, bt_component_class */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/*
- * For bt_component_class, bt_component_class_filter,
- * __BT_UPCAST_CONST
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_component_class_*_status */
#include <babeltrace2/graph/component-class.h>
-
-/*
- * For bt_component_class, bt_component_class_filter, bt_port_input,
- * bt_port_output, bt_query_executor, bt_self_component_class_filter,
- * bt_self_component_filter, bt_self_component_port_input,
- * bt_self_component_port_output, bt_value, bt_message_array_const,
- * bt_bool, bt_self_message_iterator, __BT_UPCAST
- */
#include <babeltrace2/types.h>
-
-/* For bt_logging_level */
#include <babeltrace2/logging.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_component_class, bt_component_class_sink, __BT_UPCAST_CONST */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_component_class_*_status */
#include <babeltrace2/graph/component-class.h>
-
-/*
- * For bt_component_class, bt_component_class_sink, bt_port_output,
- * bt_query_executor, bt_self_component_class_sink,
- * bt_self_component_sink, bt_self_component_port_input, bt_value,
- * __BT_UPCAST
- */
#include <babeltrace2/types.h>
-
-/* For bt_logging_level */
#include <babeltrace2/logging.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/*
- * For bt_component_class, bt_component_class_source,
- * __BT_UPCAST_CONST
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_component_class_*_status */
#include <babeltrace2/graph/component-class.h>
-
-/*
- * For bt_component_class, bt_component_class_source, bt_port_input,
- * bt_query_executor, bt_self_component_class_source,
- * bt_self_component_source, bt_self_component_port_output, bt_value,
- * bt_message_array_const, bt_bool, bt_self_message_iterator,
- * __BT_UPCAST
- */
#include <babeltrace2/types.h>
-
-/* For bt_logging_level */
#include <babeltrace2/logging.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_component_class */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_component_class_type */
#include <babeltrace2/graph/component-class-const.h>
-
-/*
- * For bt_bool, bt_component_class, bt_component_graph, bt_component,
- * bt_value, bt_port
- */
#include <babeltrace2/types.h>
-
-/* For bt_logging_level */
#include <babeltrace2/logging.h>
#ifdef __cplusplus
#include <stdint.h>
-/*
- * For bt_component, bt_component_filter, bt_port_input, bt_port_output,
- * __BT_UPCAST_CONST, bt_component_class_filter
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/*
- * For bt_component, bt_component_filter, bt_port_input,
- * __BT_UPCAST_CONST, bt_component_class_sink
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/*
- * For bt_component, bt_component_filter, bt_port_output,
- * __BT_UPCAST_CONST, bt_component_class_source
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_bool, bt_port_input, bt_port_output, bt_connection */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_bool, bt_graph */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/*
- * For bt_bool, bt_component, bt_component_class,
- * bt_component_class_filter, bt_component_class_sink,
- * bt_component_class_source, bt_component_filter, bt_component_sink,
- * bt_component_source, bt_connection, bt_graph, bt_port_input,
- * bt_port_output, bt_value
- */
#include <babeltrace2/types.h>
-
-/* For bt_logging_level */
#include <babeltrace2/logging.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_message */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_message, bt_clock_snapshot, bt_stream */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_message, bt_self_message_iterator, bt_stream */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_message, bt_clock_snapshot, bt_stream */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_message, bt_self_message_iterator, bt_stream */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_bool, bt_message, bt_event. bt_clock_class, bt_clock_snapshot */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/*
- * For bt_self_message_iterator, bt_event, bt_packet, bt_stream,
- * bt_event_class, bt_message
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_message, bt_clock_snapshot */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_self_message_iterator, bt_message, bt_clock_class */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_message, bt_packet, bt_clock_snapshot, bt_clock_class */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_message, bt_self_message_iterator, bt_packet */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_message, bt_packet, bt_clock_snapshot, bt_clock_class */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_message, bt_self_message_iterator, bt_packet */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_message, bt_clock_snapshot, bt_stream */
#include <babeltrace2/types.h>
-
-/* For bt_message_stream_clock_snapshot_state */
#include <babeltrace2/graph/message-stream-const.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_message, bt_self_message_iterator, bt_stream */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_message, bt_clock_snapshot, bt_stream */
#include <babeltrace2/types.h>
-
-/* For bt_message_stream_clock_snapshot_state */
#include <babeltrace2/graph/message-stream-const.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_message, bt_self_message_iterator, bt_stream */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_bool, bt_port, bt_connection, bt_component */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_port, bt_port_input, __BT_UPCAST_CONST */
-#include <babeltrace2/types.h>
-
#include <stdint.h>
+#include <babeltrace2/types.h>
+
#ifdef __cplusplus
extern "C" {
#endif
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_port, bt_port_output, __BT_UPCAST_CONST */
-#include <babeltrace2/types.h>
-
#include <stdint.h>
+#include <babeltrace2/types.h>
+
#ifdef __cplusplus
extern "C" {
#endif
#include <stdint.h>
-/* For bt_message_iterator_*_status */
#include <babeltrace2/graph/message-iterator.h>
-
-/*
- * For bt_port, bt_message, bt_message_iterator,
- * bt_port_output_message_iterator, bt_graph, bt_port_output,
- * bt_message_array_const, bt_bool, __BT_UPCAST
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_bool, bt_query_executor */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_query_executor, bt_component_class, bt_value */
#include <babeltrace2/types.h>
-
-/* For bt_logging_level */
#include <babeltrace2/logging.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/*
- * For bt_component_class_filter, bt_self_component_class_filter,
- * __BT_UPCAST_CONST
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/*
- * For bt_component_class_sink, bt_self_component_class_sink,
- * __BT_UPCAST_CONST
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/*
- * For bt_component_class_source, bt_self_component_class_source,
- * __BT_UPCAST_CONST
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_self_component_*_status */
#include <babeltrace2/graph/self-component.h>
-
-/*
- * For bt_component_filter, bt_self_component, bt_self_component_filter,
- * bt_self_component_port_input, bt_self_component_port_output,
- * __BT_UPCAST, __BT_UPCAST_CONST
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_message_iterator_*_status */
#include <babeltrace2/graph/message-iterator.h>
-
-/*
- * For bt_component, bt_message_iterator,
- * bt_self_component_port_input_message_iterator,
- * bt_self_component_port_input, bt_message_array_const, bt_bool,
- * __BT_UPCAST
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/*
- * For bt_port_input, bt_self_component_port,
- * bt_self_component_port_input, __BT_UPCAST, __BT_UPCAST_CONST
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/*
- * For bt_port_output, bt_self_component_port,
- * bt_self_component_port_output, __BT_UPCAST, __BT_UPCAST_CONST
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/*
- * For bt_port, bt_self_component_port, bt_self_component,
- * bt_connection, __BT_UPCAST_CONST
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_self_component_*_status */
#include <babeltrace2/graph/self-component.h>
-
-/*
- * For bt_component_sink, bt_self_component, bt_self_component_sink,
- * bt_self_component_port_input, __BT_UPCAST, __BT_UPCAST_CONST
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_self_component_*_status */
#include <babeltrace2/graph/self-component.h>
-
-/*
- * For bt_component_source, bt_self_component, bt_self_component_source,
- * bt_self_component_port_output, __BT_UPCAST, __BT_UPCAST_CONST
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_component, bt_self_component, __BT_UPCAST */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_self_component, bt_self_message_iterator, bt_self_port_output */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
#include <stddef.h>
-/*
- * For bt_bool, bt_plugin, bt_plugin_set, bt_component_class,
- * bt_component_class_source, bt_component_class_filter,
- * bt_component_class_sink
- */
#include <babeltrace2/types.h>
-
-/* For bt_property_availability */
#include <babeltrace2/property.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_component_class_type */
#include <babeltrace2/graph/component-class-const.h>
-
-/* For component class method type definitions */
#include <babeltrace2/graph/component-class-source.h>
#include <babeltrace2/graph/component-class-filter.h>
#include <babeltrace2/graph/component-class-sink.h>
-
-/* For bt_self_plugin */
#include <babeltrace2/types.h>
/*
#include <stdint.h>
-/* For bt_plugin, bt_plugin_set */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_bool, bt_uuid, bt_clock_class */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_bool, bt_uuid, bt_clock_class, bt_trace_class */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_clock_class, bt_clock_snapshot */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_property_availability */
-#include <babeltrace2/property.h>
-
-/* For bt_event_class, bt_field_class, bt_stream_class */
-#include <babeltrace2/types.h>
-
#include <stdint.h>
#include <stddef.h>
+#include <babeltrace2/property.h>
+#include <babeltrace2/types.h>
+
#ifdef __cplusplus
extern "C" {
#endif
#include <stdint.h>
-/* For bt_event_class_log_level */
#include <babeltrace2/trace-ir/event-class-const.h>
-
-/* For bt_event_class, bt_stream_class */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_event, bt_event_class, bt_field, bt_packet */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_event, bt_event_class, bt_field, bt_packet */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/*
- * For bt_bool, bt_field_class, bt_field_path,
- * bt_field_class_enumeration_mapping,
- * bt_field_class_unsigned_enumeration_mapping,
- * bt_field_class_signed_enumeration_mapping,
- * bt_field_class_enumeration_mapping_label_array, __BT_UPCAST_CONST
- */
-#include <babeltrace2/types.h>
-
#include <stdint.h>
#include <stddef.h>
+#include <babeltrace2/types.h>
+
#ifdef __cplusplus
extern "C" {
#endif
#include <stdint.h>
#include <stddef.h>
-/* For bt_bool, bt_field_class, bt_trace_class */
#include <babeltrace2/types.h>
-
-/* For bt_field_class_integer_preferred_display_base */
#include <babeltrace2/trace-ir/field-class-const.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_field_class_type */
#include <babeltrace2/trace-ir/field-class.h>
-
-/* For bt_field, bt_field_class */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_field_path, bt_field_path_item */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_field, bt_field_class */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_property_availability */
#include <babeltrace2/property.h>
-
-/*
- * For bt_packet, bt_packet_context_field, bt_stream
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_stream_class, bt_packet_context_field, bt_field */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_packet, bt_packet_context_field, bt_stream */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/*
- * For bt_bool, bt_trace_class, bt_stream_class, bt_event_class,
- * bt_stream_class
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/*
- * For bt_bool, bt_trace_class, bt_stream_class, bt_event_class,
- * bt_clock_class
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
# error "Please include <babeltrace2/babeltrace.h> instead."
#endif
-/* For bt_trace, bt_stream, bt_stream_class */
-#include <babeltrace2/types.h>
-
#include <stdint.h>
+#include <babeltrace2/types.h>
+
#ifdef __cplusplus
extern "C" {
#endif
#include <stdint.h>
-/* For bt_trace, bt_stream, bt_stream_class */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/*
- * For bt_bool, bt_uuid, bt_trace_class, bt_stream_class,
- * bt_field_class, bt_value
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_bool, bt_trace_class, bt_stream_class, bt_self_component */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/*
- * For bt_bool, bt_uuid, bt_trace, bt_stream, bt_stream_class,
- * bt_field_class, bt_value
- */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
-/* For bt_bool, bt_uuid, bt_trace, bt_trace_class, bt_stream */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
#include <stddef.h>
-/* For bt_bool, bt_value */
#include <babeltrace2/types.h>
#ifdef __cplusplus
#include <stdint.h>
#include <stddef.h>
-/* For bt_bool, bt_value */
#include <babeltrace2/types.h>
-
-/* For bt_value_type */
#include <babeltrace2/value-const.h>
#ifdef __cplusplus