Rogue Wave banner
Previous fileTop of DocumentContentsIndexNext file

A.2 Implicit Conversions

There is one place where existing source code may be incompatible with the new library. In earlier versions of Math.h++, implicit conversions could be used in a number of different settings. Now you will note that they are not always invoked for templatized functions. For example, adding a FloatVec to an IntVec was handled through implicit conversions in the old library. Because the operator+() is now templatized, it assumes that both objects being passed to it are of the same type. If it were templatized to take two different types, it would not be possible to know which type it should return.

Therefore, if you have code that mixes types or assumes implicit conversions, you may get errors when compiling or linking. If so, you need to explicitly invoke one of the global conversion functions:

or one of the conversion objects:


Previous fileTop of DocumentContentsIndexNext file

©Copyright 1999, Rogue Wave Software, Inc.
Contact Rogue Wave about documentation or support issues.