* allow reintroduce for objects, resolves #14743

git-svn-id: trunk@13832 -
This commit is contained in:
florian 2009-10-10 10:14:49 +00:00
parent 44aed2af60
commit b8a83fd997
3 changed files with 24 additions and 1 deletions

1
.gitattributes vendored
View File

@ -9320,6 +9320,7 @@ tests/webtbs/tw14617.pp svneol=native#text/plain
tests/webtbs/tw1470.pp svneol=native#text/plain
tests/webtbs/tw1472.pp svneol=native#text/plain
tests/webtbs/tw14740.pp svneol=native#text/plain
tests/webtbs/tw14743.pp svneol=native#text/pascal
tests/webtbs/tw1477.pp svneol=native#text/plain
tests/webtbs/tw1479.pp svneol=native#text/plain
tests/webtbs/tw1485.pp svneol=native#text/plain

View File

@ -1376,7 +1376,7 @@ procedure pd_reintroduce(pd:tabstractprocdef);
begin
if pd.typ<>procdef then
internalerror(200401211);
if not(is_class_or_interface(tprocdef(pd)._class)) then
if not(is_class_or_interface_or_object(tprocdef(pd)._class)) then
Message(parser_e_no_object_reintroduce);
end;

22
tests/webtbs/tw14743.pp Normal file
View File

@ -0,0 +1,22 @@
{$mode delphi}
program tbreintroduce;
type
parent = object
constructor init;
end;
child = object(parent)
constructor init(a : byte);reintroduce;
end;
constructor parent.init;
begin
end;
constructor child.init(a : byte);
begin
end;
begin
end.