0005235: Re: Error in compile error report
git-svn-id: http://code.remobjects.com/svn/pascalscript@59 5c9d2617-0215-0410-a2ee-e80e04d1c6d8
This commit is contained in:
parent
20a72b174e
commit
91bbdf9479
@ -1,3 +1,5 @@
|
||||
March 2008
|
||||
- 0005235: Re: Error in compile error report
|
||||
Feb 2008
|
||||
- 0005025: InvokeExternalMethod possible bug
|
||||
- 0003016: ranges .. in case statement not working
|
||||
|
@ -10676,6 +10676,7 @@ var
|
||||
if @FOnBeforeCleanup <> nil then
|
||||
FOnBeforeCleanup(Self); // no reason it actually read the result of this call
|
||||
FGlobalBlock.Free;
|
||||
FGlobalBlock := nil;
|
||||
|
||||
for I := 0 to FRegProcs.Count - 1 do
|
||||
TObject(FRegProcs[I]).Free;
|
||||
@ -11521,7 +11522,7 @@ begin
|
||||
else Position := csUses;
|
||||
if not ProcessUses then
|
||||
begin
|
||||
Cleanup;
|
||||
Cleanup;
|
||||
exit;
|
||||
end;
|
||||
end else if (FParser.CurrTokenId = CSTII_Procedure) or
|
||||
|
@ -540,7 +540,7 @@ procedure CompTranslateLineInfo(Sender: TPSPascalCompiler; var Pos, Row, Col: Ca
|
||||
var
|
||||
res: TPSLineInfoResults;
|
||||
begin
|
||||
if TPSScript(Sender.ID).FPP.CurrentLineInfo.GetLineInfo(Pos, Res) then
|
||||
if TPSScript(Sender.ID).FPP.CurrentLineInfo.GetLineInfo(Name, Pos, Res) then
|
||||
begin
|
||||
Pos := Res.Pos;
|
||||
Row := Res.Row;
|
||||
|
@ -74,7 +74,7 @@ type
|
||||
|
||||
procedure Clear;
|
||||
|
||||
function GetLineInfo(Pos: Cardinal; var Res: TPSLineInfoResults): Boolean;
|
||||
function GetLineInfo(const ModuleName: string; Pos: Cardinal; var Res: TPSLineInfoResults): Boolean;
|
||||
|
||||
property Current: Longint read FCurrent write FCurrent;
|
||||
|
||||
@ -258,16 +258,20 @@ begin
|
||||
Result := TPSLineInfo(FItems[i]);
|
||||
end;
|
||||
|
||||
function TPSLineInfoList.GetLineInfo(Pos: Cardinal; var Res: TPSLineInfoResults): Boolean;
|
||||
function TPSLineInfoList.GetLineInfo(const ModuleName: string; Pos: Cardinal; var Res: TPSLineInfoResults): Boolean;
|
||||
var
|
||||
i,j: Longint;
|
||||
linepos: Cardinal;
|
||||
Item: TPSLineInfo;
|
||||
lModuleName: string;
|
||||
begin
|
||||
lModuleName := FastUpperCase(lModuleName);
|
||||
|
||||
for i := FItems.Count -1 downto 0 do
|
||||
begin
|
||||
Item := FItems[i];
|
||||
if (Pos >= Item.StartPos) and (Pos < Item.EndPos) then
|
||||
if (Pos >= Item.StartPos) and (Pos < Item.EndPos) and
|
||||
(lModuleName = '') or (lModuleName = Item.FileName) then
|
||||
begin
|
||||
Res.Name := Item.FileName;
|
||||
Pos := Pos - Item.StartPos;
|
||||
@ -487,7 +491,7 @@ procedure TPSPreProcessor.AdjustMessage(Msg: TPSPascalCompilerMessage);
|
||||
var
|
||||
Res: TPSLineInfoResults;
|
||||
begin
|
||||
if CurrentLineInfo.GetLineInfo(Msg.Pos, Res) then
|
||||
if CurrentLineInfo.GetLineInfo(Msg.ModuleName, Msg.Pos, Res) then
|
||||
begin
|
||||
Msg.SetCustomPos(res.Pos, Res.Row, Res.Col);
|
||||
Msg.ModuleName := Res.Name;
|
||||
|
@ -10923,9 +10923,6 @@ begin
|
||||
end;
|
||||
else begin
|
||||
PPSVariantPointer(Res).DataDest := Pointer(FStack^);
|
||||
(*{$IFNDEF PS_NOINT64}
|
||||
FStack := Pointer(IPointer(FStack) + 4);
|
||||
{$ENDIF}*)
|
||||
Inc(Result, 4);
|
||||
end;
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user