Hi Dirk, include it as an object and not a pointer in your class, e.g.: class Dirk { private: TDatime fTime; // this will generate code like fTime.Streamer(buf) ... }; Cheers, Fons. Dirk Meier wrote: > > Hi, > > I'm trying class TDatime and link it with a root excecutable. > After generating the dictionary I receive the following message: > > aCC +p -g -w +Z > -I/afs/cern.ch/na49/library/local/ROOT/hpux10aCC/root/include -c dict.cxx > Error 226: "dict.cxx", line 5332 # No appropriate function found for call > of 'operator <<'. Last viable > candidate was "TBuffer &operator <<(TBuffer &,const TObject *)" > > ["/afs/cern.ch/na49/library/local/ROOT/hpux10aCC/root/include/TBuffer.h", > line 335]. Argument of type > 'TDatime *' could not be converted to 'const TObject *'. > R__b << fDatime; > ^^^^^^^^^^^^^^^ > Error 164: "dict.cxx", line 5332 # Integral type expected for operator > '<<'; types found were 'TBuffer &' and > 'TDatime *'. > R__b << fDatime; > ^^^^^^^^^^^^^^^ > *** Error exit code 2 > > I believe this happens because TDatime does not inherit from > class TObject. What do I have to say to compile correctly? > > Dirk -- Org: CERN, European Laboratory for Particle Physics. Mail: 1211 Geneve 23, Switzerland Phone: +41 22 7679248 E-Mail: Fons.Rademakers@cern.ch Fax: +41 22 7677910
This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:34:30 MET