The three following files show two apparent bugs:
1) The compiler seems to get confused between a standard procedure and an
object
method with the same name. In unit 1, the compiler confuses OneObj.aaa with
aaa.
So unit two fails to compile:
Error Too many arguments to function Oneobj_Aaa.
If I comment out the procedure declaration for aaa, the compiler error
disappears too.
2) Types declared in other units are still problematical. Comment out
procedure aaa
in unit 1. Now the main program fails to compile:
Error Incompatible type for argument 2 of Twoobj_Bbb.
I can't even seem to find a workaround for this (apart from abandoning the
user-defined type).
I am using the latest BETA. (30/08/98).
Russell Thamm
{---------------------------------------------------------------------------
-------------------------------}
Unit one;
INTERFACE
TYPE
RRtype = (rr_one,rr_two,rr_three,rr_four);
OneObj = OBJECT
a : Integer;
procedure aaa(r : RRType);
end;
procedure aaa;
IMPLEMENTATION
procedure OneObj.aaa(r : RRType);
begin
end;
procedure aaa;
begin
end;
END.
{--------------------------------------------}
unit two;
interface
uses one;
type
TwoObj = OBJECT
MyOne : OneObj;
procedure bbb(r : RRType);
end;
implementation
procedure TwoObj.bbb(r : RRtype);
begin
MyOne.aaa(r);
end;
end.
{-----------------------------------------------------------------}
program crap;
uses one,two;
var
MyTwo : TwoObj;
begin
MyTwo.bbb(rr_one);
end.