X-Git-Url: http://git.efficios.com/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Flib%2Flttng-ctl%2Ffilter%2Ffilter-ast.h;h=c5c73b69e8b9ee18281e33bd1f47ccf05d2dfe95;hp=7f1883f29656ba1836699b11bc3178d02dfe7966;hb=831b702b8e8914a3ca3b4905a55aed93c7d30bbf;hpb=dcd5daf2e2acb0745d5e6ff66185147007e8ed53 diff --git a/src/lib/lttng-ctl/filter/filter-ast.h b/src/lib/lttng-ctl/filter/filter-ast.h index 7f1883f29..c5c73b69e 100644 --- a/src/lib/lttng-ctl/filter/filter-ast.h +++ b/src/lib/lttng-ctl/filter/filter-ast.h @@ -67,13 +67,13 @@ enum op_type { AST_OP_MOD, AST_OP_PLUS, AST_OP_MINUS, - AST_OP_RSHIFT, - AST_OP_LSHIFT, + AST_OP_BIT_RSHIFT, + AST_OP_BIT_LSHIFT, AST_OP_AND, AST_OP_OR, - AST_OP_BIN_AND, - AST_OP_BIN_OR, - AST_OP_BIN_XOR, + AST_OP_BIT_AND, + AST_OP_BIT_OR, + AST_OP_BIT_XOR, AST_OP_EQ, AST_OP_NE, @@ -88,13 +88,14 @@ enum unary_op_type { AST_UNARY_PLUS, AST_UNARY_MINUS, AST_UNARY_NOT, - AST_UNARY_BIN_NOT, + AST_UNARY_BIT_NOT, }; enum ast_link_type { AST_LINK_UNKNOWN = 0, AST_LINK_DOT, AST_LINK_RARROW, + AST_LINK_BRACKET, }; struct filter_node { @@ -133,9 +134,12 @@ struct filter_node { */ struct filter_node *child; } u; - /* linked dot/arrow chain */ + /* prev: backward dot/arrow chain (postfix expression) */ struct filter_node *prev; + /* next: forward dot/arrow chain, generated by a visitor. */ struct filter_node *next; + /* next_bracket: linked bracket chain (prefix expression) */ + struct filter_node *next_bracket; } expression; struct { enum op_type type; @@ -177,7 +181,6 @@ struct filter_ast *filter_parser_get_ast(struct filter_parser_ctx *parser_ctx) return parser_ctx->ast; } -int filter_visitor_set_parent(struct filter_parser_ctx *ctx); int filter_visitor_print_xml(struct filter_parser_ctx *ctx, FILE *stream, int indent); int filter_visitor_ir_generate(struct filter_parser_ctx *ctx); @@ -187,5 +190,7 @@ void filter_bytecode_free(struct filter_parser_ctx *ctx); int filter_visitor_ir_check_binary_op_nesting(struct filter_parser_ctx *ctx); int filter_visitor_ir_check_binary_comparator(struct filter_parser_ctx *ctx); int filter_visitor_ir_validate_string(struct filter_parser_ctx *ctx); +int filter_visitor_ir_normalize_glob_patterns(struct filter_parser_ctx *ctx); +int filter_visitor_ir_validate_globbing(struct filter_parser_ctx *ctx); #endif /* _FILTER_AST_H */