???C++????????
???????????? ???????[ 2013/4/11 10:19:27 ] ????????
????????????????
???????????????????????????????Щ?????????????Щ???????
??????????????
1: void Test( Father oP )
2: {
3: }
4:
5: int main()
6: {
7: Father oA;
8: Test(oA);
9: return 0;
10: }
????????????????????
?????????
??????????????????????C++????????????????????й??????????????????????????????????????????????????????????????????????????ж????????????????????????????????????“???”??( ?????????????????????????????????? )
??????У?
????????沼????????
1: struct Child : Father
??????
1: struct Child
2: {
3: Father o;
4: //other
5: };
??????????麯???????????????????????沿??????????????
??????????????? Father * ???????????????? Child *????????????????????
?????? Father & ??????????????????? Child &???????з???public??But ?? why ??
????protected??private????????????е???????????????????????????Father &???????????е?????????????????????????????Υ???????????????ж??????????????
?????麯????
??????????????????
????Question?????????麯????
???????????????????????????麯??????????????????й?????????C++primer????????????????????????????????
?????麯????????????2????????????±????????
??????????????麯??????????麯???????????????????????????????????????????????????????????PS?????????????????
?????????????????????????????汾??????????????????? Father *?????????Child??????????麯????Child???
???????????????????????????
1: class Child : Father
2: {
3: int iC_;
4: void FuncC();
5: virtual void VF();
6: };
??????
???·???
??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44???????????????
2021/9/17 15:19:29???·???????·
2021/9/14 15:42:25?????????????
2021/5/28 17:25:47??????APP??????????
2021/5/8 17:01:11