home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / lang / cplus / 13681 < prev    next >
Encoding:
Text File  |  1992-09-15  |  1.1 KB  |  31 lines

  1. Newsgroups: comp.lang.c++
  2. Path: sparky!uunet!news.mentorg.com!sdl!adk
  3. From: adk@Warren.MENTORG.COM (Ajay Kamdar)
  4. Subject: Re: inline virtual functions
  5. Message-ID: <1992Sep15.150411.17717@Warren.MENTORG.COM>
  6. Organization: Mentor Graphics Corp. - IC Group
  7. References: <1992Sep15.023336.1403@cs.brown.edu>
  8. Date: Tue, 15 Sep 1992 15:04:11 GMT
  9. Lines: 20
  10.  
  11. In article <1992Sep15.023336.1403@cs.brown.edu> sdm@cs.brown.edu (Scott Meyers) writes:
  12. >For all the compilers with which I am familiar, inline virtual functions
  13. >are oxymoronic:  the function bodies are never inlined, and the object file
  14. >for each translation unit seeing the definition of the function receives a
  15. >static copy of the function.  I tested this using cfront 3.0 and g++ 2.2.2,
  16. >and both behaved as I have described, neither issuing a warning about not
  17. >inlining a function.
  18. >
  19.  
  20. Cfront based compilers will warn about noninlined virtual functions
  21. if you use the +w switch.
  22.  
  23.  
  24. - Ajay
  25.  
  26. -- 
  27. I speak for none but myself.
  28.  
  29. Ajay Kamdar                               Email : ajay_kamdar@mentorg.com
  30. Mentor Graphics, IC Group (Warren, NJ)    Phone : (908) 580-0102
  31.