summaryrefslogtreecommitdiff
path: root/src/lexer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/lexer.cpp')
-rw-r--r--src/lexer.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/lexer.cpp b/src/lexer.cpp
index 55d155d..538e088 100644
--- a/src/lexer.cpp
+++ b/src/lexer.cpp
@@ -24,17 +24,17 @@ Lexer::~Lexer()
24{ 24{
25} 25}
26 26
27void Lexer::nextToken() 27void Lexer::nextToken( int iCount )
28{ 28{
29 if( iLookAheadUsed <= 1 ) 29 if( iLookAheadUsed-iCount <= 0 )
30 { 30 {
31 iLookAheadUsed = 0; 31 iLookAheadUsed = 0;
32 iLookAheadStart = 0; 32 iLookAheadStart = 0;
33 } 33 }
34 else 34 else
35 { 35 {
36 iLookAheadStart = (iLookAheadStart+1)%iLookAheadSize; 36 iLookAheadStart = (iLookAheadStart+iCount)%iLookAheadSize;
37 iLookAheadUsed--; 37 iLookAheadUsed -= iCount;
38 } 38 }
39} 39}
40 40