moved extern declaration up to prevent compile-time errors.
[swftools.git] / src / parser.lex
index beca943..d5d81d6 100644 (file)
@@ -3,7 +3,7 @@
 #include <string.h>
 #include <stdlib.h>
 #include <stdio.h>
-#include "q.h"
+#include "../lib/q.h"
 #include "parser.h"
 
 //RVALUE        {NUMBER}|{PERCENT}|{NAME}|\"{STRING}\"|{DIM}
@@ -163,8 +163,8 @@ void handleInclude(char*text, int len)
 %x BINARY
 
 NAME    [a-zA-Z_./](-*[a-zA-Z0-9_./])*
-TWIP    ([0-9]+(\.([0-9]([05])?)?)?)
-NUMBER  [0-9]+(\.[0-9]*)?
+TWIP    (-?[0-9]+(\.([0-9]([05])?)?)?)
+NUMBER  -?[0-9]+(\.[0-9]*)?
 PERCENT         {NUMBER}%
 STRING   (\\.|[^\\"\n])*
 S       [ \n\r\t]