home *** CD-ROM | disk | FTP | other *** search
/ The C Users' Group Library 1994 August / wc-cdrom-cusersgrouplibrary-1994-08.iso / listings / v_11_09 / 1109101a < prev    next >
Text File  |  1993-07-18  |  281b  |  24 lines

  1. class string
  2.     {
  3. public:
  4.     string(const string &);
  5.     // ...
  6.     operator const char *();
  7.     size_t length();
  8.     // ...
  9. private:
  10.     char *str;
  11.     size_t len;
  12.     };
  13.  
  14. inline string::operator const char *()
  15.     {
  16.     return str;
  17.     }
  18.  
  19. inline size_t string::length()
  20.     {
  21.     return len;
  22.     }
  23.  
  24.