home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / std / cplus / 1184 < prev    next >
Encoding:
Text File  |  1992-09-15  |  773 b   |  22 lines

  1. Newsgroups: comp.std.c++
  2. Path: sparky!uunet!mcsun!sunic!aun.uninett.no!nuug!nntp.uio.no!hbf
  3. From: hbf@durin.uio.no (Hallvard B Furuseth)
  4. Subject: static virtual
  5. Message-ID: <HBF.92Sep15135918@durin.uio.no>
  6. Sender: news@ulrik.uio.no (Mr News)
  7. Nntp-Posting-Host: durin.uio.no
  8. Organization: University of Oslo, Norway
  9. Date: Tue, 15 Sep 1992 12:59:18 GMT
  10. Lines: 10
  11.  
  12. Why are static virtual functions illegal?  This would be useful for
  13. functions such as `virtual int SymbolTable::compare(char *, char *)'.
  14. It's a waste to pass a pointer to `this' to those functions.
  15.  
  16. And while I'm writing: How about static virtual variables?  These would
  17. be useful for per-class data such as a "description" fields for a class.
  18. Maybe only const variables should be allowed though.
  19. --
  20.  
  21. Hallvard
  22.