summaryrefslogtreecommitdiff
path: root/src/lexer.h
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/lexer.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/lexer.h b/src/lexer.h
index 4e6d73d..57b2865 100644
--- a/src/lexer.h
+++ b/src/lexer.h
@@ -11,6 +11,15 @@ public:
11 Lexer( Bu::Stream &rIn ); 11 Lexer( Bu::Stream &rIn );
12 virtual ~Lexer(); 12 virtual ~Lexer();
13 13
14 enum Mode
15 {
16 modeNormal,
17 modeCommand,
18 };
19
20 void setMode( Mode e ) { eMode = e; }
21 Mode getMode() const { return eMode; }
22
14 Token nextToken(); 23 Token nextToken();
15 24
16 int getScale() const { return iScale; } 25 int getScale() const { return iScale; }
@@ -20,6 +29,10 @@ public:
20 void setRadix( int i ); 29 void setRadix( int i );
21 30
22private: 31private:
32 Token nextTokenNormal();
33 Token nextTokenCommand();
34
35private:
23 Bu::Stream &rIn; 36 Bu::Stream &rIn;
24 Bu::String sBuf; 37 Bu::String sBuf;
25 int iBufPos; 38 int iBufPos;
@@ -27,6 +40,7 @@ private:
27 int iRadix; 40 int iRadix;
28 char numRangeTop; 41 char numRangeTop;
29 char ascRangeTop; 42 char ascRangeTop;
43 Mode eMode;
30}; 44};
31 45
32#endif 46#endif