home *** CD-ROM | disk | FTP | other *** search
/ Microsoftware Monthly 19…2 Programming Power Tools / MASO9512.ISO / cpptutor / cpptutor.arj / CH06 / A06123.WAV (.mp3) < prev    next >
Waveform Audio File Format  |  1993-11-25  |  287.2 KB  |  1 channel  |  11,025 sample rate  |  26 seconds
Transcription: If the copy constructor for the fraction class were omitted, the example main function would still work. The default copy constructor makes a member-by-member copy of the data members of the class. This default copy causes problems in many situations. For example, if a data member of the class is a pointer, the default copy constructor duplicates the pointer rather than what is pointed to.