summary refs log tree commit diff stats
path: root/nim
diff options
context:
space:
mode:
authorAndreas Rumpf <rumpf_a@web.de>2009-05-10 22:35:58 +0200
committerAndreas Rumpf <rumpf_a@web.de>2009-05-10 22:35:58 +0200
commitc7e144f97810630d8ab4f396f299c6355fc93ba7 (patch)
treef013e592eb209b66d3b56401e8c96d58929d57b1 /nim
parentd54b333e7e3df82732b70cade2e4b8591e4c2572 (diff)
downloadNim-c7e144f97810630d8ab4f396f299c6355fc93ba7.tar.gz
added missing files;change config for bug #374441
Diffstat (limited to 'nim')
-rw-r--r--nim/highlite.pas3
-rw-r--r--nim/strutils.pas8
2 files changed, 9 insertions, 2 deletions
diff --git a/nim/highlite.pas b/nim/highlite.pas
index ad7a6f724..1867268d3 100644
--- a/nim/highlite.pas
+++ b/nim/highlite.pas
@@ -358,7 +358,8 @@ begin
     end
   end;
   g.len := pos - g.pos;
-  if (g.kind <> gtEof) and (g.len <= 0) then InternalError('nimNextToken');
+  if (g.kind <> gtEof) and (g.len <= 0) then 
+    InternalError('nimNextToken: ' + toString(g.buf));
   g.pos := pos;
 end;
 
diff --git a/nim/strutils.pas b/nim/strutils.pas
index cd07105be..377d3abc6 100644
--- a/nim/strutils.pas
+++ b/nim/strutils.pas
@@ -1,7 +1,7 @@
 //
 //
 //           The Nimrod Compiler
-//        (c) Copyright 2008 Andreas Rumpf
+//        (c) Copyright 2009 Andreas Rumpf
 //
 //    See the file "copying.txt", included in this
 //    distribution, for details about the copyright.
@@ -45,6 +45,7 @@ function toString(i: BiggestInt): string; overload;
 //function toString(i: int): string; overload;
 function ToStringF(const r: Real): string; overload;
 function ToString(b: Boolean): string; overload;
+function ToString(b: PChar): string; overload;
 
 function IntToStr(i: BiggestInt; minChars: int): string;
 
@@ -415,6 +416,11 @@ begin
   result := sysUtils.intToStr(i);
 end;
 
+function ToString(b: PChar): string; overload;
+begin
+  result := string(b);
+end;
+
 function normalize(const s: string): string;
 var
   i: int;