|
| |||
|
| |||
|
| |||
|
|
PitBull mauler; Canine pooch; pooch = mauler; Answer: excess fields get chopped off. In the code above, the program forgets all about how many people
mauler
has killed.Note that the reverse conversion (Canine to PitBull) doesn't make any sense (What value would we place in the peopleKilled field?) and is illegal. However, you can define such a conversion yourself using operator= if you really need it.