Chapter 19. Casts
Cast: The form in which something is made or constructed.
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 ...