mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-06 22:25:59 +02:00
git-svn-id: trunk@33164 -
This commit is contained in:
parent
edcc251c76
commit
4039c1835c
1
.gitattributes
vendored
1
.gitattributes
vendored
@ -14961,6 +14961,7 @@ tests/webtbs/tw29471.pp svneol=native#text/plain
|
||||
tests/webtbs/tw2949.pp svneol=native#text/plain
|
||||
tests/webtbs/tw2953.pp svneol=native#text/plain
|
||||
tests/webtbs/tw29546.pp svneol=native#text/pascal
|
||||
tests/webtbs/tw29547.pp svneol=native#text/plain
|
||||
tests/webtbs/tw2956.pp svneol=native#text/plain
|
||||
tests/webtbs/tw2958.pp svneol=native#text/plain
|
||||
tests/webtbs/tw29585.pp svneol=native#text/plain
|
||||
|
37
tests/webtbs/tw29547.pp
Normal file
37
tests/webtbs/tw29547.pp
Normal file
@ -0,0 +1,37 @@
|
||||
program Test;
|
||||
|
||||
{$mode objfpc}
|
||||
|
||||
type
|
||||
Point2D = record
|
||||
x, y: Single;
|
||||
end;
|
||||
|
||||
Line = record
|
||||
start : Point2D;
|
||||
endP : Point2D;
|
||||
end;
|
||||
|
||||
function LineFrom(p1, p2: Point2D): Line;
|
||||
begin
|
||||
result.start := p1;
|
||||
result.endP := p2;
|
||||
end;
|
||||
|
||||
procedure Main();
|
||||
var
|
||||
l: Line;
|
||||
pt1, pt2: Point2D;
|
||||
begin
|
||||
pt1.x := 1.0;
|
||||
pt2.x := 2.0;
|
||||
l := LineFrom(pt1, pt2);
|
||||
if (l.start.x<>1.0) or
|
||||
(l.endp.x<>2.0) then
|
||||
halt(1);
|
||||
end;
|
||||
|
||||
begin
|
||||
Main();
|
||||
end.
|
||||
|
Loading…
Reference in New Issue
Block a user