1 #include <ozulis/ast/ast.hh>
2 #include <ozulis/core/assert.hh>
4 #include "bison/parser.hh"
5 #include "bison/lexer.hh"
8 int mugiwara_parse(yyscan_t yyscanner
, ozulis::ast::FilePtr
& module
);
13 Parser::parse(FILE * stream
)
15 ozulis::ast::FilePtr file
= 0;
18 mugiwara_lex_init(&scanner
);
19 mugiwara_set_in(stream
, scanner
);
20 assert_msg(!mugiwara_parse(scanner
, file
), "parse error");
21 mugiwara_lex_destroy(scanner
);