<<Depth Exploration C ++ Model>> Question (Chapter 2) (Part 2)

zhaozj2021-02-11  189

Chapter II: Technical Solutions

2.1 Construction of Default Constructor:

1. What is the role of "explicit" in C ? (P39)

2. In this case, the compiler will synthesize a "nontrivial default constructor"? (P41-47)

3. Can the compiler synthesizes the "Nontrol DEFAULT CONSTRUctor" to meet the needs of the program? why? (P42)

4. In C different compilation modules, how does the compiler avoid multiple DEFAULT CONSTRUCTOR? (P41)

5. If a Class contains multiple class member objects, how do C call these objects? (P43)

6. What happens when a Class of Virtual Function is constructed? (P45)

7. What happens when the Class inherited from Virtual Base Class is constructed? (P46)

8. Any class If you don't define a default constructor, it will be synthetic, right? (47)

9. The Default Constructor synthesized by the compiler will clearly set the default value of each MEMBER in the Class, right? (47)

2.2 Construction of Copy Constructor:

1. There are three situations that will be the initial value of another Class Object as another Class Object. (P48)

2. What is the process of MEMBERWISE INITIALIZATION? (P49-P50)

3. What is the standard for TRIVIAL? (P51)? (P51)

4. What is "bitwise copy semantics? (52)

5. When does a class not appear "Bitwise Copy Semantics? (53)

6. Why is a class of a Class, is not "Bitwise Copy Semantics, mainly why? (P55)

7. Why is the existence of a Virtual Base Class cause "Bitwise Copy Semantics" 无效? (P57-58)

转载请注明原文地址:https://www.9cbs.com/read-4944.html

New Post(0)