Implement support for brackets in filter expressions
[lttng-tools.git] / src / lib / lttng-ctl / filter / filter-ir.h
index 5c3fa4ab52f97332095bc9923fde9c1c188a0771..c07050df58d666e9736e9095b1a74c847aa81c96 100644 (file)
@@ -38,6 +38,8 @@ enum ir_data_type {
        IR_DATA_FLOAT,
        IR_DATA_FIELD_REF,
        IR_DATA_GET_CONTEXT_REF,
+       IR_DATA_FIELD_REF_INDEX,
+       IR_DATA_GET_CONTEXT_REF_INDEX,
 };
 
 enum ir_op_type {
@@ -56,16 +58,34 @@ enum ir_side {
        IR_RIGHT,
 };
 
+enum ir_load_string_type {
+       /* Plain, no globbing at all: `hello world`. */
+       IR_LOAD_STRING_TYPE_PLAIN = 0,
+
+       /* Star at the end only: `hello *`. */
+       IR_LOAD_STRING_TYPE_GLOB_STAR_END,
+
+       /* At least one star, anywhere, but not at the end only: `he*wor*`. */
+       IR_LOAD_STRING_TYPE_GLOB_STAR,
+};
+
 struct ir_op_root {
        struct ir_op *child;
 };
 
 struct ir_op_load {
        union {
-               char *string;
+               struct {
+                       enum ir_load_string_type type;
+                       char *value;
+               } string;
                int64_t num;
                double flt;
                char *ref;
+               struct {
+                       char *symbol;
+                       uint64_t index;
+               } ref_index;
        } u;
 };
 
This page took 0.023688 seconds and 4 git commands to generate.