X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=include%2Flttng%2Fevent-expr-internal.h;h=469fd17bbf32f685ff05f42760aae07eaaf6c82c;hp=048aaff18665b3a73de50ca38829a4f504442e7a;hb=b66cbf1731486ab4dc7e0b2e1c3fa05cc5360c19;hpb=1aa9c49c60b7d7370ceafc3ac076de423de22b7f diff --git a/include/lttng/event-expr-internal.h b/include/lttng/event-expr-internal.h index 048aaff18..469fd17bb 100644 --- a/include/lttng/event-expr-internal.h +++ b/include/lttng/event-expr-internal.h @@ -8,11 +8,11 @@ #ifndef LTTNG_EVENT_EXPR_INTERNAL_H #define LTTNG_EVENT_EXPR_INTERNAL_H -#include #include #include struct lttng_bytecode; +struct mi_writer; struct lttng_event_expr { enum lttng_event_expr_type type; @@ -50,15 +50,18 @@ struct lttng_event_expr_array_field_element { static inline bool lttng_event_expr_is_lvalue(const struct lttng_event_expr *expr) { - assert(expr); + LTTNG_ASSERT(expr); return expr->type == LTTNG_EVENT_EXPR_TYPE_EVENT_PAYLOAD_FIELD || expr->type == LTTNG_EVENT_EXPR_TYPE_CHANNEL_CONTEXT_FIELD || expr->type == LTTNG_EVENT_EXPR_TYPE_APP_SPECIFIC_CONTEXT_FIELD || expr->type == LTTNG_EVENT_EXPR_TYPE_ARRAY_FIELD_ELEMENT; } -LTTNG_HIDDEN int lttng_event_expr_to_bytecode(const struct lttng_event_expr *expr, struct lttng_bytecode **bytecode_out); +enum lttng_error_code lttng_event_expr_mi_serialize( + const struct lttng_event_expr *expression, + struct mi_writer *writer); + #endif /* LTTNG_EVENT_EXPR_INTERNAL_H */