summary refs log tree commit diff stats
path: root/compiler/lexer.nim
diff options
context:
space:
mode:
authorAraq <rumpf_a@web.de>2013-05-04 19:10:12 +0200
committerAraq <rumpf_a@web.de>2013-05-04 19:10:12 +0200
commit23bd3ccd8bc1b6aae931a3754ad478849c3be82d (patch)
treef96245ae0b14225ba2f008d7949ce2b07e436ea7 /compiler/lexer.nim
parentf8af7ed6b46d045b82b5b70370846fe857b5a39d (diff)
parent05fd46cdd1ce26b714888182ab69dcf2cd3d6ed2 (diff)
downloadNim-23bd3ccd8bc1b6aae931a3754ad478849c3be82d.tar.gz
Merge branch 'master' into newparser
Diffstat (limited to 'compiler/lexer.nim')
-rw-r--r--compiler/lexer.nim16
1 files changed, 8 insertions, 8 deletions
diff --git a/compiler/lexer.nim b/compiler/lexer.nim
index 93649c888..6660ff65c 100644
--- a/compiler/lexer.nim
+++ b/compiler/lexer.nim
@@ -16,7 +16,7 @@
 # DOS or Macintosh text files, even when it is not the native format.
 
 import 
-  hashes, options, msgs, strutils, platform, idents, lexbase, llstream, 
+  hashes, options, msgs, strutils, platform, idents, nimlexbase, llstream,
   wordrecg
 
 const 
@@ -508,10 +508,10 @@ proc HandleCRLF(L: var TLexer, pos: int): int =
   case L.buf[pos]
   of CR:
     registerLine()
-    result = lexbase.HandleCR(L, pos)
+    result = nimlexbase.HandleCR(L, pos)
   of LF:
     registerLine()
-    result = lexbase.HandleLF(L, pos)
+    result = nimlexbase.HandleLF(L, pos)
   else: result = pos
   
 proc getString(L: var TLexer, tok: var TToken, rawMode: bool) = 
@@ -537,7 +537,7 @@ proc getString(L: var TLexer, tok: var TToken, rawMode: bool) =
         pos = HandleCRLF(L, pos)
         buf = L.buf
         add(tok.literal, tnl)
-      of lexbase.EndOfFile: 
+      of nimlexbase.EndOfFile: 
         var line2 = L.linenumber
         L.LineNumber = line
         lexMessagePos(L, errClosingTripleQuoteExpected, L.lineStart)
@@ -559,7 +559,7 @@ proc getString(L: var TLexer, tok: var TToken, rawMode: bool) =
         else:
           inc(pos) # skip '"'
           break
-      elif c in {CR, LF, lexbase.EndOfFile}: 
+      elif c in {CR, LF, nimlexbase.EndOfFile}: 
         lexMessage(L, errClosingQuoteExpected)
         break 
       elif (c == '\\') and not rawMode: 
@@ -640,7 +640,7 @@ proc scanComment(L: var TLexer, tok: var TToken) =
   var col = getColNumber(L, pos)
   while true:
     var lastBackslash = -1
-    while buf[pos] notin {CR, LF, lexbase.EndOfFile}:
+    while buf[pos] notin {CR, LF, nimlexbase.EndOfFile}:
       if buf[pos] == '\\': lastBackslash = pos+1
       add(tok.literal, buf[pos])
       inc(pos)
@@ -648,7 +648,7 @@ proc scanComment(L: var TLexer, tok: var TToken) =
       # a backslash is a continuation character if only followed by spaces
       # plus a newline:
       while buf[lastBackslash] == ' ': inc(lastBackslash)
-      if buf[lastBackslash] notin {CR, LF, lexbase.EndOfFile}:
+      if buf[lastBackslash] notin {CR, LF, nimlexbase.EndOfFile}:
         # false positive:
         lastBackslash = -1
 
@@ -795,7 +795,7 @@ proc rawGetTok(L: var TLexer, tok: var TToken) =
     else:
       if c in OpChars: 
         getOperator(L, tok)
-      elif c == lexbase.EndOfFile:
+      elif c == nimlexbase.EndOfFile:
         tok.toktype = tkEof
         tok.indent = 0
       else: