to convert a _DecimalT class template class to a floating point data type, use source code similar to that found in the following figure.
Figure 303. Example of Converting a _DecimalT Class Template to a Floating Point Data Type
|
The output is shown below.
+--------------------------------------------------------------------------------+ | f1=123.45 | | f2=-123456 | +--------------------------------------------------------------------------------+
(C) Copyright IBM Corporation 1992, 2005. All Rights Reserved.