* disallow 64-bit property index specifiers on 64-bit CPUs, since they were not

handled correctly there anyway (they were silently truncated to 32-bit)

git-svn-id: trunk@27061 -
This commit is contained in:
nickysn 2014-03-09 21:05:53 +00:00
parent 044891fd94
commit dcc2354760
3 changed files with 19 additions and 2 deletions

1
.gitattributes vendored
View File

@ -9563,6 +9563,7 @@ tests/tbf/tb0235.pp svneol=native#text/pascal
tests/tbf/tb0236.pp svneol=native#text/pascal
tests/tbf/tb0237.pp svneol=native#text/pascal
tests/tbf/tb0238.pp svneol=native#text/pascal
tests/tbf/tb0239.pp svneol=native#text/pascal
tests/tbf/ub0115.pp svneol=native#text/plain
tests/tbf/ub0149.pp svneol=native#text/plain
tests/tbf/ub0158a.pp svneol=native#text/plain

View File

@ -460,9 +460,7 @@ implementation
procedure matching requires equal parameters }
if is_constnode(pt) and
is_ordinal(pt.resultdef)
{$ifndef cpu64bitaddr}
and (not is_64bitint(pt.resultdef))
{$endif cpu64bitaddr}
then
begin
if is_integer(pt.resultdef) then

18
tests/tbf/tb0239.pp Normal file
View File

@ -0,0 +1,18 @@
{ %FAIL }
program tb0239;
{$MODE objfpc}
type
TMyClass = class
function GetMyProperty(Index: Integer): Integer;
property MyProperty: Integer index 10000000000000000 read GetMyProperty;
end;
function TMyClass.GetMyProperty(Index: Integer): Integer;
begin
Result := 10;
end;
begin
end.