projects
/
supertux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fixed a bug. Replaced switch with button.
[supertux.git]
/
tools
/
miniswig
/
lexer.ll
diff --git
a/tools/miniswig/lexer.ll
b/tools/miniswig/lexer.ll
index
ac699ab
..
954138b
100644
(file)
--- a/
tools/miniswig/lexer.ll
+++ b/
tools/miniswig/lexer.ll
@@
-1,4
+1,6
@@
%{
%{
+#include <config.h>
+
#include <math.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <stdlib.h>
#include <string.h>
@@
-7,6
+9,10
@@
#include "parser.hpp"
#include "globals.hpp"
#include "parser.hpp"
#include "globals.hpp"
+// there seems to be a bug in flex that adds some ECHO directives
+// in some rules, we don't need debug output
+#define ECHO {}
+
#define YY_NEVER_INTERACTIVE 1
#define YY_DECL int yylex(YYSTYPE* yylval)
#define YY_NEVER_INTERACTIVE 1
#define YY_DECL int yylex(YYSTYPE* yylval)
@@
-94,6
+100,8
@@
public { return T_PUBLIC; }
protected { return T_PROTECTED; }
private { return T_PRIVATE; }
namespace { return T_NAMESPACE; }
protected { return T_PROTECTED; }
private { return T_PRIVATE; }
namespace { return T_NAMESPACE; }
+__suspend { return T_SUSPEND; }
+__custom { return T_CUSTOM; }
[a-zA-Z_][a-zA-Z_0-9]* {
Namespace* ns = search_namespace;
if(ns == 0)
[a-zA-Z_][a-zA-Z_0-9]* {
Namespace* ns = search_namespace;
if(ns == 0)