摘要: 主要有两种方式:利用友元、类成员方法。 #include using namespace std; /** *演示修饰符重载 *一般都用成员方法重载 *特殊的没有办法修改核心库的用友元的方法来重载 例如weight = weight; } ~Chicken() { delete this; } int getWeight(); ... 阅读全文
posted @ 2018-04-24 17:29 花兮 阅读(327) 评论(0) 推荐(0) 编辑