由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Programming版 - one question about struct
相关主题
one more interview questionC calls C++ library
定义linked list最后一行什么意思?c++ initialize struct
C++菜鸟问题请教: class versus structure.请教struct inside class的问题(C++)
The C++ questions I've been askedC++ operator = overloading用copy & swap有啥优点
不明白C++的一个地方大家觉得C++复杂在哪里?
C++ Q01: private inheritance.c++越写越没有信心,觉得自己水平弱的不行
C++ Q09: delete dynamic array一个inheritance 的问题
What does the default constructor do?question overloading ++ error
相关话题的讨论汇总
话题: struct话题: default话题: class
进入Programming版参与讨论
1 (共1页)
c***g
发帖数: 472
1
I know that struct is identical as class in C++ except the default access
level.
So... the struct has constructor destructor and copy constructor ?
s***e
发帖数: 793
2
sure, struct has every thing. virtural function , function overloading ,
operator overloading .
another issue is that the struct inheritance is public inheritance by
default.

【在 c***g 的大作中提到】
: I know that struct is identical as class in C++ except the default access
: level.
: So... the struct has constructor destructor and copy constructor ?

c***g
发帖数: 472
3
what's the default inheritance of class?

【在 s***e 的大作中提到】
: sure, struct has every thing. virtural function , function overloading ,
: operator overloading .
: another issue is that the struct inheritance is public inheritance by
: default.

t****t
发帖数: 6806
4
class/struct Child : {default} Parent {
//if (keyword == class) default=private;
//else default=public;
};

【在 c***g 的大作中提到】
: what's the default inheritance of class?
1 (共1页)
进入Programming版参与讨论
相关主题
question overloading ++ error不明白C++的一个地方
问个构造函数的问题C++ Q01: private inheritance.
C & C++ mixing questionC++ Q09: delete dynamic array
why use static function here?What does the default constructor do?
one more interview questionC calls C++ library
定义linked list最后一行什么意思?c++ initialize struct
C++菜鸟问题请教: class versus structure.请教struct inside class的问题(C++)
The C++ questions I've been askedC++ operator = overloading用copy & swap有啥优点
相关话题的讨论汇总
话题: struct话题: default话题: class