codetools: AbsoluteToLineCol allow SrcLen and SrcLen+1

git-svn-id: trunk@20512 -
This commit is contained in:
mattias 2009-06-08 09:03:42 +00:00
parent 277169e2ca
commit e88c1fadd4

View File

@ -627,7 +627,7 @@ procedure TSourceLog.AbsoluteToLineCol(Position: integer;
var l,r,m:integer;
begin
BuildLineRanges;
if (FLineCount=0) or (Position<1) or (Position>=fSrcLen) then begin
if (FLineCount=0) or (Position<1) or (Position>fSrcLen+1) then begin
Line:=-1;
Column:=-1;
exit;