+ test for proper line info retrival from dlls/sos

git-svn-id: trunk@11007 -
This commit is contained in:
florian 2008-05-18 18:26:17 +00:00
parent 02de4a081c
commit 1fe749c90c
3 changed files with 38 additions and 0 deletions

2
.gitattributes vendored
View File

@ -7477,6 +7477,8 @@ tests/test/tinterface5.pp svneol=native#text/plain
tests/test/tinterrupt.pp svneol=native#text/plain
tests/test/tintfdef.pp svneol=native#text/plain
tests/test/tintuint.pp svneol=native#text/plain
tests/test/tlib1.pp svneol=native#text/plain
tests/test/tlib1a.pp svneol=native#text/plain
tests/test/tlibrary1.pp svneol=native#text/plain
tests/test/tlibrary2.pp svneol=native#text/plain
tests/test/tlibrary3.pp svneol=native#text/plain

20
tests/test/tlib1.pp Normal file
View File

@ -0,0 +1,20 @@
{ %opt=-gl }
{$ifdef unix}
uses
dl;
{$endif unix}
procedure p(var a : pointer);external 'tlib1a' name 'p';
var
s1,s2 : string;
l : longint;
a : pointer;
begin
p(a);
GetLineInfo(PtrUInt(a),s1,s2,l);
writeln('Func: ',s1,' Source: ',s2,' Line: ',l);
if (s1<>'P') or (s2<>'tlib1a.pp') or (l<>7) then
halt(1);
writeln('ok');
end.

16
tests/test/tlib1a.pp Normal file
View File

@ -0,0 +1,16 @@
{ %norun }
{$goto on}
library tlib1a;
procedure p(var a : pointer);
label
we;
begin
we:
a:=@we;
end;
exports p;
begin
end.