added parser/parser.h for a common YYSTYPE definition location

git-svn-id: svn://anubis/fart/trunk@116 7f9b0f55-74a9-4bce-be96-3c2cd072584d
This commit is contained in:
Josh Holtrop 2009-02-17 02:13:24 +00:00
parent ecc06433fc
commit 2a816c1c1a
3 changed files with 9 additions and 2 deletions

7
parser/parser.h Normal file
View File

@ -0,0 +1,7 @@
#ifndef PARSER_H
#define PARSER_H PARSER_H
#define YYSTYPE refptr<Node>
#endif

View File

@ -4,7 +4,7 @@
%{ %{
#include "nodes.h" #include "nodes.h"
#define YYSTYPE refptr<Node> #include "parser.h"
#include "parser.tab.hh" #include "parser.tab.hh"
%} %}

View File

@ -9,6 +9,7 @@
#include "util/refptr.h" #include "util/refptr.h"
#include "shapes/Shape.h" /* includes all shape types */ #include "shapes/Shape.h" /* includes all shape types */
#include "nodes.h" #include "nodes.h"
#include "parser.h"
using namespace std; using namespace std;
int yylex(void); int yylex(void);
@ -25,7 +26,6 @@ int yywrap()
return 1; return 1;
} }
#define YYSTYPE refptr<Node>
static Scene * g_scene; static Scene * g_scene;