[lazarus] no method in an ancestor class

Bernd Jürgens bernd at promedico.com
Mon Jan 10 15:12:46 EST 2000


Hello Shane,


thanks for your reply.

> update your sources once.  Go into your Lazarus directory 
> and do an cvs update.  Seems your extctrls.pp file may 
> be out of date.  If that doesn't work, delete that 
> file and do the update to make sure it pulls it.

I deleted the file and did cvs to get a new one. Still the same.
I even deleted the whole tree and did a cvs checkout. 

Compiler error is:

> extctrls.pp(77,6) Error: There is no method in an ancestor class to be
> overridden: TPAGE.READSTATE(TREADER)

extctrls.pp contains:

  TPage = class(TCustomControl)
  private
    fPageCaption: TLabel;
  protected
    procedure CreateWnd; override;
    procedure ReadState(Reader: TAbstractReader); override;
    procedure Paint;


The hierarchy descends like this:
TPage -> TCustomControl -> TWinControl -> TControl -> TComponent.


In classesinc.h we find the declaration 

TComponent = class(TPersistent)      
protected 
procedure ReadState(Reader: TAbstractReader); virtual;          


and it´s built correct:
bernd at lara:/opt/fpc/lazarus/lcl > objdump --syms ../../fcl/linux/classes.o |
grep READSTA
00007a30 g     F .text  00000007
_CLASSES$$_$$_TCOMPONENT_$$_READSTATE$TABSTRACTREADER 

What´s wrong ?

Bernd Juergens






More information about the Lazarus mailing list