H
huanzhugege
Unregistered / Unconfirmed
GUEST, unregistred user!
type
TStack = class(TObject)
private
m_iMaxSize: Integer;
m_iCurSize: Integer;
public
constructor Create(aSize:Integer)
virtual;
destructor Free
virtual;
function IsEmpty: Boolean;
procedure Clear;
function IsFull: Boolean;
procedure Push
overload
virtual
abstract;
function Pop: TObject
overload
virtual
abstract;
function GetTop: OLEVariant
overload
virtual
abstract;
end;
TOperandStack = class(TStack)
private
m_iContainer: array of Integer;
public
constructor Create(aSize:Integer)
override;
destructor Free
override;
procedure Push(aValue:LongInt)
reintroduce
overload
override;
//method 'push' not found in base class
function Pop: LongInt
reintroduce
overload
override;
function GetTop: LongInt
reintroduce
overload
override;
end;
为什么在注释的那一句中提示 method 'push' not found in base class
TStack = class(TObject)
private
m_iMaxSize: Integer;
m_iCurSize: Integer;
public
constructor Create(aSize:Integer)
virtual;
destructor Free
virtual;
function IsEmpty: Boolean;
procedure Clear;
function IsFull: Boolean;
procedure Push
overload
virtual
abstract;
function Pop: TObject
overload
virtual
abstract;
function GetTop: OLEVariant
overload
virtual
abstract;
end;
TOperandStack = class(TStack)
private
m_iContainer: array of Integer;
public
constructor Create(aSize:Integer)
override;
destructor Free
override;
procedure Push(aValue:LongInt)
reintroduce
overload
override;
//method 'push' not found in base class
function Pop: LongInt
reintroduce
overload
override;
function GetTop: LongInt
reintroduce
overload
override;
end;
为什么在注释的那一句中提示 method 'push' not found in base class