From: Mathieu Desnoyers Date: Tue, 7 Aug 2012 15:19:52 +0000 (-0400) Subject: Filter fix: support bison 2.6 X-Git-Tag: v2.1.0-rc1~37 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=95b9bd903e097fa120f5815604d6765f7b0f2596;p=lttng-tools.git Filter fix: support bison 2.6 Bison 2.6 generates warnings and errors if filter-ast.h is not included before filter-parser.h. Reported-by: Christian Babeux Signed-off-by: Mathieu Desnoyers --- diff --git a/src/lib/lttng-ctl/filter-ast.h b/src/lib/lttng-ctl/filter-ast.h index a42ac164d..97793c00b 100644 --- a/src/lib/lttng-ctl/filter-ast.h +++ b/src/lib/lttng-ctl/filter-ast.h @@ -22,6 +22,10 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ +/* + * Note: filter-ast.h should be included before filter-parser.h. + */ + #include #include diff --git a/src/lib/lttng-ctl/filter-grammar-test.c b/src/lib/lttng-ctl/filter-grammar-test.c index b47b1e950..2b9a27dc2 100644 --- a/src/lib/lttng-ctl/filter-grammar-test.c +++ b/src/lib/lttng-ctl/filter-grammar-test.c @@ -26,8 +26,8 @@ #include #include #include -#include "filter-parser.h" #include "filter-ast.h" +#include "filter-parser.h" #include "filter-bytecode.h" int main(int argc, char **argv) diff --git a/src/lib/lttng-ctl/filter-parser.y b/src/lib/lttng-ctl/filter-parser.y index d6f00a095..ea433522d 100644 --- a/src/lib/lttng-ctl/filter-parser.y +++ b/src/lib/lttng-ctl/filter-parser.y @@ -29,8 +29,8 @@ #include #include #include -#include "filter-parser.h" #include "filter-ast.h" +#include "filter-parser.h" int yydebug; int filter_parser_debug = 0; diff --git a/src/lib/lttng-ctl/filter-visitor-generate-ir.c b/src/lib/lttng-ctl/filter-visitor-generate-ir.c index dd0d7ffaf..899713ee6 100644 --- a/src/lib/lttng-ctl/filter-visitor-generate-ir.c +++ b/src/lib/lttng-ctl/filter-visitor-generate-ir.c @@ -26,8 +26,8 @@ #include #include #include -#include "filter-parser.h" #include "filter-ast.h" +#include "filter-parser.h" #include "filter-ir.h" static diff --git a/src/lib/lttng-ctl/filter-visitor-ir-check-binary-comparator.c b/src/lib/lttng-ctl/filter-visitor-ir-check-binary-comparator.c index fff9b5168..13da71edb 100644 --- a/src/lib/lttng-ctl/filter-visitor-ir-check-binary-comparator.c +++ b/src/lib/lttng-ctl/filter-visitor-ir-check-binary-comparator.c @@ -26,8 +26,8 @@ #include #include #include -#include "filter-parser.h" #include "filter-ast.h" +#include "filter-parser.h" #include "filter-ir.h" static diff --git a/src/lib/lttng-ctl/filter-visitor-ir-check-binary-op-nesting.c b/src/lib/lttng-ctl/filter-visitor-ir-check-binary-op-nesting.c index 64048a584..08488deff 100644 --- a/src/lib/lttng-ctl/filter-visitor-ir-check-binary-op-nesting.c +++ b/src/lib/lttng-ctl/filter-visitor-ir-check-binary-op-nesting.c @@ -26,8 +26,8 @@ #include #include #include -#include "filter-parser.h" #include "filter-ast.h" +#include "filter-parser.h" #include "filter-ir.h" static diff --git a/src/lib/lttng-ctl/filter-visitor-set-parent.c b/src/lib/lttng-ctl/filter-visitor-set-parent.c index 2cc5f53f6..2ad707f6d 100644 --- a/src/lib/lttng-ctl/filter-visitor-set-parent.c +++ b/src/lib/lttng-ctl/filter-visitor-set-parent.c @@ -26,8 +26,8 @@ #include #include #include -#include "filter-parser.h" #include "filter-ast.h" +#include "filter-parser.h" static int update_child(struct filter_node *parent, diff --git a/src/lib/lttng-ctl/filter-visitor-xml.c b/src/lib/lttng-ctl/filter-visitor-xml.c index bf52724ef..b3a1ac959 100644 --- a/src/lib/lttng-ctl/filter-visitor-xml.c +++ b/src/lib/lttng-ctl/filter-visitor-xml.c @@ -26,8 +26,8 @@ #include #include #include -#include "filter-parser.h" #include "filter-ast.h" +#include "filter-parser.h" #define fprintf_dbg(fd, fmt, args...) fprintf(fd, "%s: " fmt, __func__, ## args) diff --git a/src/lib/lttng-ctl/lttng-ctl.c b/src/lib/lttng-ctl/lttng-ctl.c index b6487b7c2..ba0c4c826 100644 --- a/src/lib/lttng-ctl/lttng-ctl.c +++ b/src/lib/lttng-ctl/lttng-ctl.c @@ -33,8 +33,8 @@ #include #include -#include "filter-parser.h" #include "filter-ast.h" +#include "filter-parser.h" #include "filter-bytecode.h" #include "memstream.h"