mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-18 15:49:17 +02:00
+ test for mantis #36381 (seems already fixed)
git-svn-id: trunk@47337 -
This commit is contained in:
parent
71b8d5643d
commit
49fbe53cf3
1
.gitattributes
vendored
1
.gitattributes
vendored
@ -18416,6 +18416,7 @@ tests/webtbs/tw36212.pp svneol=native#text/pascal
|
|||||||
tests/webtbs/tw36215.pp svneol=native#text/pascal
|
tests/webtbs/tw36215.pp svneol=native#text/pascal
|
||||||
tests/webtbs/tw3628.pp svneol=native#text/plain
|
tests/webtbs/tw3628.pp svneol=native#text/plain
|
||||||
tests/webtbs/tw3634.pp svneol=native#text/plain
|
tests/webtbs/tw3634.pp svneol=native#text/plain
|
||||||
|
tests/webtbs/tw36381.pp svneol=native#text/plain
|
||||||
tests/webtbs/tw36388.pp svneol=native#text/pascal
|
tests/webtbs/tw36388.pp svneol=native#text/pascal
|
||||||
tests/webtbs/tw36389.pp svneol=native#text/pascal
|
tests/webtbs/tw36389.pp svneol=native#text/pascal
|
||||||
tests/webtbs/tw36496a.pp svneol=native#text/pascal
|
tests/webtbs/tw36496a.pp svneol=native#text/pascal
|
||||||
|
32
tests/webtbs/tw36381.pp
Normal file
32
tests/webtbs/tw36381.pp
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
{$mode objfpc}
|
||||||
|
|
||||||
|
program test;
|
||||||
|
|
||||||
|
type
|
||||||
|
TVec2 = record
|
||||||
|
x, y: single;
|
||||||
|
end;
|
||||||
|
|
||||||
|
function ViewToWorld (x, y: single): TVec2; overload;
|
||||||
|
begin
|
||||||
|
result.x := x;
|
||||||
|
result.y := y;
|
||||||
|
end;
|
||||||
|
|
||||||
|
function ViewToWorld (pt: TVec2): TVec2; overload; inline;
|
||||||
|
begin
|
||||||
|
result := ViewToWorld(pt.x, pt.y);
|
||||||
|
end;
|
||||||
|
|
||||||
|
var
|
||||||
|
pt: TVec2;
|
||||||
|
begin
|
||||||
|
pt.x:=1.0;
|
||||||
|
pt.y:=2.0;
|
||||||
|
// ERROR: Internal error 2009112601
|
||||||
|
pt := ViewToWorld(pt);
|
||||||
|
if pt.x<>1.0 then
|
||||||
|
halt(1);
|
||||||
|
if pt.y<>2.0 then
|
||||||
|
halt(2);
|
||||||
|
end.
|
Loading…
Reference in New Issue
Block a user