Google


   


You are here: CodeIdol.com > C++ > C++ Coding Standards: 101 Rules, Guidelines, and Best Practices > Practice Safe Overriding

SAVE
Digg
Shown on del.icio.us del.icio.us
See Whos Talking About This on Technorati Technorati
I've Reddit reddit

C++ Coding Standards: 101 Rules, Guidelines, and Best Practices



38. SummaryDiscussionExamplesReferences...



Override responsibly: When overriding a virtual function, preserve substitutability; in particular, observe the function's pre- and post-conditions in the base class. Don't change default arguments...

read more: Summary


Although derived classes usually add more state (i.e., data members), they model subsets, not supersets, of their base classes. In correct inheritance, a derived class...

read more: Discussion


Example: Ostrich. If class Bird defines the virtual function Fly and you derive a new class Ostrich (a notoriously flightless bird) from Bird, how do...

read more: Examples


[Dewhurst03] §73-74, §• [Sutter00] §21 • [Keffer95] p. 18...

read more: References

SAVE
Digg
Shown on del.icio.us del.icio.us
See Whos Talking About This on Technorati Technorati
I've Reddit reddit

You are here: CodeIdol.com > C++ > C++ Coding Standards: 101 Rules, Guidelines, and Best Practices > Practice Safe Overriding


ADBRITE ads links
   
Related tags







Popular Categories
Unix books and guides

AJAX popular information
C# language guides
Windows books and cookbooks

.......








Business Key Top Sites

be number one
rate your site


Окна ПВХ и остекление Лоджий. Отзыв о компании Имтэкс.

    С 2009 года мы стали переводить структура сайта на различные языки. Сайт теперь будет содержать книги не только на английском языке, но также и на других европейских языках, в том числе и на Русском языке.

    Русский Polski Francais Deutsch
    support sitemap terms

© CodeIdol Labs, 2007 - 2009