Ambiguous overloaded call?
From: Raptor (bogus_at_none.com)
Date: 02/23/05
- Next message: thanat0s: "Using setthreadaffinity on delphi"
- Previous message: Colin Basterfield: "Re: Anyone using DUint on SourceForge? Or other app testing libraries?"
- Next in thread: Nicolai Hansen: "Re: Ambiguous overloaded call?"
- Reply: Nicolai Hansen: "Re: Ambiguous overloaded call?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Tue, 22 Feb 2005 19:10:52 -0800
It would be nice if over 2% of the libraries out there actually compiled.
Sigh.
I'd like to incorporate application exercising/testing into my application
development. Maybe.
Trying DUnit on SourceForge.
Attempt to compile gives me an "Ambiguous overloaded call to CheckEquals"
error. Two of them, actually.
These are the calls which raise the error:
-------------
procedure TAbstractTest.CheckEqualsBin(expected, actual: longword;
msg: string = ''; digits:
integer=32);
begin
CheckEquals(IntToBin(expected, digits), IntToBin(actual, digits), msg);
end;
procedure TAbstractTest.CheckEqualsHex(expected, actual: longword;
msg: string = ''; digits: integer=8);
begin
CheckEquals(IntToHex(expected, digits), IntToHex(actual, digits), msg);
end;
-------------
This is the list of overloaded CheckEquals:
-------------
TAbstractTest = class(TInterfacedObject, ITest)
protected
...
public
procedure CheckEquals(expected, actual: extended; msg: string = '');
overload; virtual;
procedure CheckEquals(expected, actual: extended; delta: extended; msg:
string = ''); overload; virtual;
procedure CheckEquals(expected, actual: integer; msg: string = '');
overload; virtual;
procedure CheckEquals(expected, actual: string; msg: string = '');
overload; virtual;
{$IFNDEF CLR}
procedure CheckEquals(expected, actual: WideString; msg: string = '');
overload; virtual;
{$ENDIF}
procedure CheckEquals(expected, actual: boolean; msg: string = '');
overload; virtual;
procedure CheckEquals(expected, actual: TClass; msg: string = '');
overload; virtual;
-------------
I'm not that familiar with overloading. Can anyone see where the ambiguity
might be?
Raptor
- Next message: thanat0s: "Using setthreadaffinity on delphi"
- Previous message: Colin Basterfield: "Re: Anyone using DUint on SourceForge? Or other app testing libraries?"
- Next in thread: Nicolai Hansen: "Re: Ambiguous overloaded call?"
- Reply: Nicolai Hansen: "Re: Ambiguous overloaded call?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|