C++ Q&A

时间:2014-05-12 15:06:06   收藏:0   阅读:315

Why can I access private variables in the copy constructor?

The access modifiers work on class level, and not on object level.That is, two objects of the same class can access each others private members. stackoverflow link

C++ Q&A,布布扣,bubuko.com

评论(0
© 2014 mamicode.com 版权所有 京ICP备13008772号-2  联系我们:gaon5@hotmail.com
迷上了代码!