home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / lang / pascal / 8473 < prev    next >
Encoding:
Text File  |  1993-01-23  |  1.1 KB  |  40 lines

  1. Newsgroups: comp.lang.pascal
  2. Path: sparky!uunet!mcsun!sunic!aun.uninett.no!nuug!nntp.uio.no!achristo
  3. From: achristo@pons.uio.no (Alf Christophersen)
  4. Subject: Re: Questions about Constructors and pointers to objects in TP 6
  5. Message-ID: <930023.163019.achristo@nutri1>
  6. Lines: 26
  7. Sender: news@ulrik.uio.no (Mr News)
  8. Nntp-Posting-Host: nutri1.uio.no
  9. Organization: University of Oslo
  10. Date: Sat, 23 Jan 1993 15:30:19 GMT
  11. Lines: 27
  12.  
  13.  
  14. I think maybe you lost something important in the TDerived
  15. decalration!
  16.  
  17. >
  18. >    type
  19. >      PBase = ^TBase;
  20. >      TBase = object
  21. >        constructor Init(...);
  22. >        destructor  Done; virtual;
  23. >        function    IsA: string; virtual;
  24. >      end;
  25. >
  26. >      PDerived = ^TDerived;
  27. >      TDerived = object(TBASe)
  28.                         ^^^^^^^ <- You need to declare what
  29.                         TDerived is derived from to have this
  30.                         example to work :-)
  31. >        constructor Init(...);      { if necessary }
  32. >        destructor  Done; virtual;  { if necessary }
  33. >        function    IsA: string; virtual;
  34. >      end;
  35. >      ...
  36.  
  37. Alf Christophersen
  38. Dep. of Nutrition Res.
  39. University of Oslo, Norway
  40.