Skip to Content
Imperfect C++ Practical Solutions for Real-Life Programming
book

Imperfect C++ Practical Solutions for Real-Life Programming

by Matthew Wilson
October 2004
Intermediate to advanced
624 pages
16h 2m
English
Addison-Wesley Professional
Content preview from Imperfect C++ Practical Solutions for Real-Life Programming

Chapter 19. Casts

CastThe form in which something is made or constructed.

Implicit Conversion

On our behalf, the C++ compiler will carry out a multitude of implicit conversions between types. Just because they're implicit, however, doesn't mean that they're trivial. Conversions between integral and floating-point types can involve significant work [Meye1996, Stro1997]; conversion between integral types of difference sizes can involve truncation or sign extension [Stro1997]; conversions between pointer types of virtually derived classes on an implementing instance involve pointer adjustment [Lipp1996]. The problems, from the point of view of accuracy, of conversions were mentioned in Chapter 13, and are described in detail in [Stro1997]. In this ...

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.
Start your free trial

You might also like

Practical C++ Metaprogramming

Practical C++ Metaprogramming

Edouard Alligand, Joel Falcou

Publisher Resources

ISBN: 0321228774Purchase book