From 8eb2798776ef83afd187d65b8eb471a4b2f3c219 Mon Sep 17 00:00:00 2001 From: Henner Zeller Date: Tue, 14 May 2019 21:07:26 -0700 Subject: Make the generated *.tab.hh include all the headers needed to define the union. --- frontends/ilang/ilang_parser.y | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'frontends/ilang') diff --git a/frontends/ilang/ilang_parser.y b/frontends/ilang/ilang_parser.y index 0df792997..44c99906a 100644 --- a/frontends/ilang/ilang_parser.y +++ b/frontends/ilang/ilang_parser.y @@ -47,6 +47,15 @@ USING_YOSYS_NAMESPACE %define api.prefix {rtlil_frontend_ilang_yy} +/* The union is defined in the header, so we need to provide all the + * includes it requires + */ +%code requires { +#include +#include +#include "frontends/ilang/ilang_frontend.h" +} + %union { char *string; int integer; @@ -451,4 +460,3 @@ conn_stmt: delete $2; delete $3; }; - -- cgit v1.2.3