Type Cast Operators
This material does not actually belong to this chapter. However, it could not be discussed earlier in the book because it is based on advanced concepts of inheritance, templates, and exceptions.
Actually, I had doubts about discussing these cast operators at all. They are relatively new to the C++ language, and the experience of using them in industry is rather limited. There is no strong evidence that these operators are better than the standard simple casts we used on so many occasions before.
However, these cast operators represent a set of interesting software engineering ideas, and it is definitely worth becoming familiar with them. As far as using them in your practice—see for yourself.
As you have seen on many previous ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access