Phases of Construction

The construction of an object consists of several phases, including constructing its base and embedded objects, assigning a this pointer, creating the virtual table, and invoking the constructor’s body. The construction of an object declared as const and/or volatile has an additional phase that turns an object into a const/volatile one. Therefore, you should not assume any “constness” of an object unless it has been fully constructed. And of course, a constructor of a const/volatile object can modify its object.

Share the Post:
Share on facebook
Share on twitter
Share on linkedin

Overview

Recent Articles: