home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / lang / cplus / 13608 < prev    next >
Encoding:
Internet Message Format  |  1992-09-14  |  1.1 KB

  1. Path: sparky!uunet!pmafire!news.dell.com!swrinde!elroy.jpl.nasa.gov!usc!sol.ctr.columbia.edu!ira.uka.de!slsvaat!us-es.sel.de!brendan
  2. From: brendan@us-es.sel.de (Dalton)
  3. Newsgroups: comp.lang.c++
  4. Subject: Virtual methods
  5. Message-ID: <1992Sep14.145950.7661@us-es.sel.de>
  6. Date: 14 Sep 92 14:59:50 GMT
  7. References: <#7vnafk.feustel@netcom.com>
  8. Sender: news@us-es.sel.de
  9. Organization: SEL-Alcatel LTS Dept. US/ES
  10. Lines: 15
  11.  
  12. feustel@netcom.com (David Feustel) writes:
  13.  
  14. |> Coplien's book "Advanced C++" makes the point that very little overhead
  15. |> would be incurred in most programe even if all functions were declared
  16. |> virtual and that some programs might even run faster than equivalent C
  17. |> programs using switch constructs to achieve the same effects.
  18.  
  19. This reminds me of a question which I've been meaning to ask for some
  20. time now. Ignoring performance issues, why would one not declare every
  21. method in a class virtual? What circumstances might preclude its use?
  22.  
  23. -- 
  24. Brendan J. Dalton (brendan@us-es.sel.de)
  25. ----------------------------------------
  26. Ritheann an fear seo ar phoitin
  27.