[Python-checkins] python/nondist/sandbox/decimal/tests abs.decTest, 1.5, 1.6 add.decTest, 1.5, 1.6 base.decTest, 1.5, 1.6 clamp.decTest, 1.5, 1.6 compare.decTest, 1.5, 1.6 divide.decTest, 1.5, 1.6 divideint.decTest, 1.5, 1.6 inexact.decTest, 1.5, 1.6 max.decTest, 1.5, 1.6 min.decTest, 1.5, 1.6 minus.decTest, 1.5, 1.6 multiply.decTest, 1.5, 1.6 normalize.decTest, 1.5, 1.6 plus.decTest, 1.5, 1.6 power.decTest, 1.5, 1.6 quantize.decTest, 1.3, 1.4 randomBound32.decTest, 1.5, 1.6 randoms.decTest, 1.6, 1.7 remainder.decTest, 1.5, 1.6 remainderNear.decTest, 1.5, 1.6 rounding.decTest, 1.5, 1.6 samequantum.decTest, 1.1, 1.2 squareroot.decTest, 1.5, 1.6 subtract.decTest, 1.5, 1.6 tointegral.decTest, 1.2, 1.3

facundobatista at users.sourceforge.net facundobatista at users.sourceforge.net
Mon Jun 21 17:48:34 EDT 2004


Update of /cvsroot/python/python/nondist/sandbox/decimal/tests
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24685

Modified Files:
	abs.decTest add.decTest base.decTest clamp.decTest 
	compare.decTest divide.decTest divideint.decTest 
	inexact.decTest max.decTest min.decTest minus.decTest 
	multiply.decTest normalize.decTest plus.decTest power.decTest 
	quantize.decTest randomBound32.decTest randoms.decTest 
	remainder.decTest remainderNear.decTest rounding.decTest 
	samequantum.decTest squareroot.decTest subtract.decTest 
	tointegral.decTest 
Log Message:
Updated test cases from Cowlishaw.

Index: abs.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/abs.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** abs.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- abs.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,161 ****
! ------------------------------------------------------------------------
! -- abs.decTest -- decimal absolute value                              --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.35
! 
! -- This set of tests primarily tests the existence of the operator.
! -- Additon, subtraction, rounding, and more overflows are tested
! -- elsewhere.
! 
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minexponent: -999
! extended: 1
! 
! absx001 abs '1'      -> '1'
! absx002 abs '-1'     -> '1'
! absx003 abs '1.00'   -> '1.00'
! absx004 abs '-1.00'  -> '1.00'
! absx005 abs '0'      -> '0'
! absx006 abs '0.00'   -> '0.00'
! absx007 abs '00.0'   -> '0.0'
! absx008 abs '00.00'  -> '0.00'
! absx009 abs '00'     -> '0'
! 
! absx010 abs '-2'     -> '2'
! absx011 abs '2'      -> '2'
! absx012 abs '-2.00'  -> '2.00'
! absx013 abs '2.00'   -> '2.00'
! absx014 abs '-0'     -> '0'
! absx015 abs '-0.00'  -> '0.00'
! absx016 abs '-00.0'  -> '0.0'
! absx017 abs '-00.00' -> '0.00'
! absx018 abs '-00'    -> '0'
! 
! absx020 abs '-2000000' -> '2000000'
! absx021 abs '2000000'  -> '2000000'
! precision: 7
! absx022 abs '-2000000' -> '2000000'
! absx023 abs '2000000'  -> '2000000'
! precision: 6
! absx024 abs '-2000000' -> '2.00000E+6' Rounded
! absx025 abs '2000000'  -> '2.00000E+6' Rounded
! precision: 3
! absx026 abs '-2000000' -> '2.00E+6' Rounded
! absx027 abs '2000000'  -> '2.00E+6' Rounded
! 
! absx030 abs '+0.1'            -> '0.1'
! absx031 abs '-0.1'            -> '0.1'
! absx032 abs '+0.01'           -> '0.01'
! absx033 abs '-0.01'           -> '0.01'
! absx034 abs '+0.001'          -> '0.001'
! absx035 abs '-0.001'          -> '0.001'
! absx036 abs '+0.000001'       -> '0.000001'
! absx037 abs '-0.000001'       -> '0.000001'
! absx038 abs '+0.000000000001' -> '1E-12'
! absx039 abs '-0.000000000001' -> '1E-12'
! 
! -- examples from decArith
! precision: 9
! absx040 abs '2.1'     ->  '2.1'
! absx041 abs '-100'    ->  '100'
! absx042 abs '101.5'   ->  '101.5'
! absx043 abs '-101.5'  ->  '101.5'
! 
! -- more fixed, potential LHS swaps/overlays if done by subtract 0
! precision: 9
! absx060 abs '-56267E-10'  -> '0.0000056267'
! absx061 abs '-56267E-5'   -> '0.56267'
! absx062 abs '-56267E-2'   -> '562.67'
! absx063 abs '-56267E-1'   -> '5626.7'
! absx065 abs '-56267E-0'   -> '56267'
! 
! -- overflow tests
! maxexponent: 999999999
! minexponent: -999999999
! precision: 3
! absx120 abs 9.999E+999999999 -> Infinity Inexact Overflow Rounded
! 
! -- subnormals and underflow
! precision: 3
! maxexponent: 999
! minexponent: -999
! absx210 abs  1.00E-999        ->   1.00E-999
! absx211 abs  0.1E-999         ->   1E-1000   Subnormal
! absx212 abs  0.10E-999        ->   1.0E-1000 Subnormal
! absx213 abs  0.100E-999       ->   1.0E-1000 Subnormal Rounded
! absx214 abs  0.01E-999        ->   1E-1001   Subnormal
! -- next is rounded to Emin
! absx215 abs  0.999E-999       ->   1.00E-999 Inexact Rounded Subnormal Underflow
! absx216 abs  0.099E-999       ->   1.0E-1000 Inexact Rounded Subnormal Underflow
! absx217 abs  0.009E-999       ->   1E-1001   Inexact Rounded Subnormal Underflow
! absx218 abs  0.001E-999       ->   0E-1001   Inexact Rounded Subnormal Underflow
! absx219 abs  0.0009E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! absx220 abs  0.0001E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! 
! absx230 abs -1.00E-999        ->   1.00E-999
! absx231 abs -0.1E-999         ->   1E-1000   Subnormal
! absx232 abs -0.10E-999        ->   1.0E-1000 Subnormal
! absx233 abs -0.100E-999       ->   1.0E-1000 Subnormal Rounded
! absx234 abs -0.01E-999        ->   1E-1001   Subnormal
! -- next is rounded to Emin
! absx235 abs -0.999E-999       ->   1.00E-999 Inexact Rounded Subnormal Underflow
! absx236 abs -0.099E-999       ->   1.0E-1000 Inexact Rounded Subnormal Underflow
! absx237 abs -0.009E-999       ->   1E-1001   Inexact Rounded Subnormal Underflow
! absx238 abs -0.001E-999       ->   0E-1001   Inexact Rounded Subnormal Underflow
! absx239 abs -0.0009E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! absx240 abs -0.0001E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! 
! -- long operand tests
! maxexponent: 999
! minexponent: -999
! precision: 9
! absx301 abs 12345678000  -> 1.23456780E+10 Rounded
! absx302 abs 1234567800   -> 1.23456780E+9 Rounded
! absx303 abs 1234567890   -> 1.23456789E+9 Rounded
! absx304 abs 1234567891   -> 1.23456789E+9 Inexact Rounded
! absx305 abs 12345678901  -> 1.23456789E+10 Inexact Rounded
! absx306 abs 1234567896   -> 1.23456790E+9 Inexact Rounded
! 
! precision: 15
! absx321 abs 12345678000  -> 12345678000
! absx322 abs 1234567800   -> 1234567800
! absx323 abs 1234567890   -> 1234567890
! absx324 abs 1234567891   -> 1234567891
! absx325 abs 12345678901  -> 12345678901
! absx326 abs 1234567896   -> 1234567896
! 
! 
! -- Specials
! precision:   9
! 
! -- specials
! absx520 abs 'Inf'    -> 'Infinity'
! absx521 abs '-Inf'   -> 'Infinity'
! absx522 abs   NaN    ->  NaN
! absx523 abs  sNaN    ->  NaN   Invalid_operation
! absx524 abs   NaN22  ->  NaN22
! absx525 abs  sNaN33  ->  NaN33 Invalid_operation
! absx526 abs  -NaN22  -> -NaN22
! absx527 abs -sNaN33  -> -NaN33 Invalid_operation
! 
! -- Null tests
! absx900 abs  # -> NaN Invalid_operation
! 
--- 1,161 ----
! ------------------------------------------------------------------------
! -- abs.decTest -- decimal absolute value                              --
! -- Copyright (c) IBM Corporation, 1981, 2004.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.38
! 
! -- This set of tests primarily tests the existence of the operator.
! -- Additon, subtraction, rounding, and more overflows are tested
! -- elsewhere.
! 
! precision:   9
! rounding:    half_up
! maxExponent: 384
! minexponent: -383
! extended: 1
! 
! absx001 abs '1'      -> '1'
! absx002 abs '-1'     -> '1'
! absx003 abs '1.00'   -> '1.00'
! absx004 abs '-1.00'  -> '1.00'
! absx005 abs '0'      -> '0'
! absx006 abs '0.00'   -> '0.00'
! absx007 abs '00.0'   -> '0.0'
! absx008 abs '00.00'  -> '0.00'
! absx009 abs '00'     -> '0'
! 
! absx010 abs '-2'     -> '2'
! absx011 abs '2'      -> '2'
! absx012 abs '-2.00'  -> '2.00'
! absx013 abs '2.00'   -> '2.00'
! absx014 abs '-0'     -> '0'
! absx015 abs '-0.00'  -> '0.00'
! absx016 abs '-00.0'  -> '0.0'
! absx017 abs '-00.00' -> '0.00'
! absx018 abs '-00'    -> '0'
! 
! absx020 abs '-2000000' -> '2000000'
! absx021 abs '2000000'  -> '2000000'
! precision: 7
! absx022 abs '-2000000' -> '2000000'
! absx023 abs '2000000'  -> '2000000'
! precision: 6
! absx024 abs '-2000000' -> '2.00000E+6' Rounded
! absx025 abs '2000000'  -> '2.00000E+6' Rounded
! precision: 3
! absx026 abs '-2000000' -> '2.00E+6' Rounded
! absx027 abs '2000000'  -> '2.00E+6' Rounded
! 
! absx030 abs '+0.1'            -> '0.1'
! absx031 abs '-0.1'            -> '0.1'
! absx032 abs '+0.01'           -> '0.01'
! absx033 abs '-0.01'           -> '0.01'
! absx034 abs '+0.001'          -> '0.001'
! absx035 abs '-0.001'          -> '0.001'
! absx036 abs '+0.000001'       -> '0.000001'
! absx037 abs '-0.000001'       -> '0.000001'
! absx038 abs '+0.000000000001' -> '1E-12'
! absx039 abs '-0.000000000001' -> '1E-12'
! 
! -- examples from decArith
! precision: 9
! absx040 abs '2.1'     ->  '2.1'
! absx041 abs '-100'    ->  '100'
! absx042 abs '101.5'   ->  '101.5'
! absx043 abs '-101.5'  ->  '101.5'
! 
! -- more fixed, potential LHS swaps/overlays if done by subtract 0
! precision: 9
! absx060 abs '-56267E-10'  -> '0.0000056267'
! absx061 abs '-56267E-5'   -> '0.56267'
! absx062 abs '-56267E-2'   -> '562.67'
! absx063 abs '-56267E-1'   -> '5626.7'
! absx065 abs '-56267E-0'   -> '56267'
! 
! -- overflow tests
! maxexponent: 999999999
! minexponent: -999999999
! precision: 3
! absx120 abs 9.999E+999999999 -> Infinity Inexact Overflow Rounded
! 
! -- subnormals and underflow
! precision: 3
! maxexponent: 999
! minexponent: -999
! absx210 abs  1.00E-999        ->   1.00E-999
! absx211 abs  0.1E-999         ->   1E-1000   Subnormal
! absx212 abs  0.10E-999        ->   1.0E-1000 Subnormal
! absx213 abs  0.100E-999       ->   1.0E-1000 Subnormal Rounded
! absx214 abs  0.01E-999        ->   1E-1001   Subnormal
! -- next is rounded to Emin
! absx215 abs  0.999E-999       ->   1.00E-999 Inexact Rounded Subnormal Underflow
! absx216 abs  0.099E-999       ->   1.0E-1000 Inexact Rounded Subnormal Underflow
! absx217 abs  0.009E-999       ->   1E-1001   Inexact Rounded Subnormal Underflow
! absx218 abs  0.001E-999       ->   0E-1001   Inexact Rounded Subnormal Underflow
! absx219 abs  0.0009E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! absx220 abs  0.0001E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! 
! absx230 abs -1.00E-999        ->   1.00E-999
! absx231 abs -0.1E-999         ->   1E-1000   Subnormal
! absx232 abs -0.10E-999        ->   1.0E-1000 Subnormal
! absx233 abs -0.100E-999       ->   1.0E-1000 Subnormal Rounded
! absx234 abs -0.01E-999        ->   1E-1001   Subnormal
! -- next is rounded to Emin
! absx235 abs -0.999E-999       ->   1.00E-999 Inexact Rounded Subnormal Underflow
! absx236 abs -0.099E-999       ->   1.0E-1000 Inexact Rounded Subnormal Underflow
! absx237 abs -0.009E-999       ->   1E-1001   Inexact Rounded Subnormal Underflow
! absx238 abs -0.001E-999       ->   0E-1001   Inexact Rounded Subnormal Underflow
! absx239 abs -0.0009E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! absx240 abs -0.0001E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! 
! -- long operand tests
! maxexponent: 999
! minexponent: -999
! precision: 9
! absx301 abs 12345678000  -> 1.23456780E+10 Rounded
! absx302 abs 1234567800   -> 1.23456780E+9 Rounded
! absx303 abs 1234567890   -> 1.23456789E+9 Rounded
! absx304 abs 1234567891   -> 1.23456789E+9 Inexact Rounded
! absx305 abs 12345678901  -> 1.23456789E+10 Inexact Rounded
! absx306 abs 1234567896   -> 1.23456790E+9 Inexact Rounded
! 
! precision: 15
! absx321 abs 12345678000  -> 12345678000
! absx322 abs 1234567800   -> 1234567800
! absx323 abs 1234567890   -> 1234567890
! absx324 abs 1234567891   -> 1234567891
! absx325 abs 12345678901  -> 12345678901
! absx326 abs 1234567896   -> 1234567896
! 
! 
! -- Specials
! precision:   9
! 
! -- specials
! absx520 abs 'Inf'    -> 'Infinity'
! absx521 abs '-Inf'   -> 'Infinity'
! absx522 abs   NaN    ->  NaN
! absx523 abs  sNaN    ->  NaN   Invalid_operation
! absx524 abs   NaN22  ->  NaN22
! absx525 abs  sNaN33  ->  NaN33 Invalid_operation
! absx526 abs  -NaN22  -> -NaN22
! absx527 abs -sNaN33  -> -NaN33 Invalid_operation
! 
! -- Null tests
! absx900 abs  # -> NaN Invalid_operation
! 

Index: add.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/add.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** add.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- add.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,1120 ****
! ------------------------------------------------------------------------
! -- add.decTest -- decimal addition                                    --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
[...2218 lines suppressed...]
! addx1141 add         10E-101 -1e-200  ->  9E-101     Subnormal Inexact Rounded Underflow
! addx1142 add          1E-101 -1e-200  ->  0E-101     Subnormal Inexact Rounded Underflow
! addx1143 add          0E-101 -1e-200  -> -0E-101     Subnormal Inexact Rounded Underflow
! addx1144 add          1E-102 -1e-200  ->  0E-101     Subnormal Inexact Rounded Underflow
! 
! addx1151 add      10000E-102 -1e-200  ->  9.99E-99  Subnormal Inexact Rounded Underflow
! addx1152 add       1000E-102 -1e-200  ->  9.9E-100  Subnormal Inexact Rounded Underflow
! addx1153 add        100E-102 -1e-200  ->  9E-101   Subnormal Inexact Rounded Underflow
! addx1154 add         10E-102 -1e-200  ->  0E-101     Subnormal Inexact Rounded Underflow
! addx1155 add          1E-102 -1e-200  ->  0E-101     Subnormal Inexact Rounded Underflow
! addx1156 add          0E-102 -1e-200  -> -0E-101     Subnormal Inexact Rounded Underflow
! addx1157 add          1E-103 -1e-200  ->  0E-101     Subnormal Inexact Rounded Underflow
! 
! addx1160 add        100E-105 -1e-101  -> -0E-101 Subnormal Inexact Rounded Underflow
! addx1161 add        100E-105 -1e-201  ->  0E-101 Subnormal Inexact Rounded Underflow
! 
! 
! -- Null tests
! addx9990 add 10  # -> NaN Invalid_operation
! addx9991 add  # 10 -> NaN Invalid_operation

Index: base.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/base.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** base.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- base.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,1266 ****
! ------------------------------------------------------------------------
! -- base.decTest -- base decimal <--> string conversions               --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
[...2503 lines suppressed...]
! basx1026 tosci 1e-2147483649 -> 0E-1000000014 Underflow Subnormal Inexact Rounded
! -- same unbalanced
! precision:   7
! maxExponent: 96
! minexponent: -95
! basx1031 tosci 1e+2147483649 -> Infinity Overflow Inexact Rounded
! basx1032 tosci 1e+2147483648 -> Infinity Overflow Inexact Rounded
! basx1033 tosci 1e+2147483647 -> Infinity Overflow Inexact Rounded
! basx1034 tosci 1e-2147483647 -> 0E-101 Underflow Subnormal Inexact Rounded
! basx1035 tosci 1e-2147483648 -> 0E-101 Underflow Subnormal Inexact Rounded
! basx1036 tosci 1e-2147483649 -> 0E-101 Underflow Subnormal Inexact Rounded
! 
! -- check for double-rounded subnormals
! precision:   5
! maxexponent: 79
! minexponent: -79
! basx1041 toSci     1.52444E-80  ->  1.524E-80 Inexact Rounded Subnormal Underflow
! basx1042 toSci     1.52445E-80  ->  1.524E-80 Inexact Rounded Subnormal Underflow
! basx1043 toSci     1.52446E-80  ->  1.524E-80 Inexact Rounded Subnormal Underflow
! 

Index: clamp.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/clamp.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** clamp.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- clamp.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,197 ****
! ------------------------------------------------------------------------
! -- clamp.decTest -- clamped exponent tests (format-independent)       --
! -- Copyright (c) IBM Corporation, 2000, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.35
! 
! -- This set of tests uses the same limits as the 8-byte concrete
! -- representation, but applies clamping without using format-specific
! -- conversions.
! 
! extended:    1
! precision:   16
! rounding:    half_even
! maxExponent: 384
! minExponent: -383
! clamp:       1
! 
! -- General testcases
! 
! -- Normality
! clam010 apply   1234567890123456   ->  1234567890123456
! clam011 apply   1234567890123456.0 ->  1234567890123456 Rounded
! clam012 apply   1234567890123456.1 ->  1234567890123456 Rounded Inexact
! clam013 apply  -1234567890123456   -> -1234567890123456
! clam014 apply  -1234567890123456.0 -> -1234567890123456 Rounded
! clam015 apply  -1234567890123456.1 -> -1234567890123456 Rounded Inexact
! 
! 
! -- Nmax and similar
! clam022 apply   9.999999999999999E+384  -> 9.999999999999999E+384
! clam024 apply   1.234567890123456E+384  -> 1.234567890123456E+384
! -- fold-downs (more below)
! clam030 apply   1.23E+384               -> 1.230000000000000E+384 Clamped
! clam032 apply   1E+384                  -> 1.000000000000000E+384 Clamped
! 
! clam051 apply   12345                   -> 12345
! clam053 apply   1234                    -> 1234
! clam055 apply   123                     -> 123
! clam057 apply   12                      -> 12
! clam059 apply   1                       -> 1
! clam061 apply   1.23                    -> 1.23
! clam063 apply   123.45                  -> 123.45
! 
! -- Nmin and below
! clam071 apply   1E-383                  -> 1E-383
! clam073 apply   1.000000000000000E-383  -> 1.000000000000000E-383
! clam075 apply   1.000000000000001E-383  -> 1.000000000000001E-383
! 
! clam077 apply   0.100000000000000E-383  -> 1.00000000000000E-384  Subnormal
! clam079 apply   0.000000000000010E-383  -> 1.0E-397               Subnormal
! clam081 apply   0.00000000000001E-383   -> 1E-397                 Subnormal
! clam083 apply   0.000000000000001E-383  -> 1E-398                 Subnormal
! 
! -- underflows
! clam090 apply   1e-398                  -> #0000000000000001  Subnormal
! clam091 apply   1.9e-398                -> #0000000000000002  Subnormal Underflow Inexact Rounded
! clam092 apply   1.1e-398                -> #0000000000000001  Subnormal Underflow Inexact Rounded
! clam093 apply   1.00000000001e-398      -> #0000000000000001  Subnormal Underflow Inexact Rounded
! clam094 apply   1.00000000000001e-398   -> #0000000000000001  Subnormal Underflow Inexact Rounded
! clam095 apply   1.000000000000001e-398  -> #0000000000000001  Subnormal Underflow Inexact Rounded
! clam096 apply   0.1e-398                -> #0000000000000000  Subnormal Underflow Inexact Rounded
! clam097 apply   0.00000000001e-398      -> #0000000000000000  Subnormal Underflow Inexact Rounded
! clam098 apply   0.00000000000001e-398   -> #0000000000000000  Subnormal Underflow Inexact Rounded
! clam099 apply   0.000000000000001e-398  -> #0000000000000000  Subnormal Underflow Inexact Rounded
! 
! -- Same again, negatives
! -- Nmax and similar
! clam122 apply  -9.999999999999999E+384  -> -9.999999999999999E+384
! clam124 apply  -1.234567890123456E+384  -> -1.234567890123456E+384
! -- fold-downs (more below)
! clam130 apply  -1.23E+384               -> -1.230000000000000E+384 Clamped
! clam132 apply  -1E+384                  -> -1.000000000000000E+384 Clamped
! 
! clam151 apply  -12345                   -> -12345
! clam153 apply  -1234                    -> -1234
! clam155 apply  -123                     -> -123
! clam157 apply  -12                      -> -12
! clam159 apply  -1                       -> -1
! clam161 apply  -1.23                    -> -1.23
! clam163 apply  -123.45                  -> -123.45
! 
! -- Nmin and below
! clam171 apply  -1E-383                  -> -1E-383
! clam173 apply  -1.000000000000000E-383  -> -1.000000000000000E-383
! clam175 apply  -1.000000000000001E-383  -> -1.000000000000001E-383
! 
! clam177 apply  -0.100000000000000E-383  -> -1.00000000000000E-384  Subnormal
! clam179 apply  -0.000000000000010E-383  -> -1.0E-397               Subnormal
! clam181 apply  -0.00000000000001E-383   -> -1E-397                 Subnormal
! clam183 apply  -0.000000000000001E-383  -> -1E-398                 Subnormal
! 
! -- underflows
! clam189 apply   -1e-398                 -> #8000000000000001  Subnormal
! clam190 apply   -1.0e-398               -> #8000000000000001  Subnormal Rounded
! clam191 apply   -1.9e-398               -> #8000000000000002  Subnormal Underflow Inexact Rounded
! clam192 apply   -1.1e-398               -> #8000000000000001  Subnormal Underflow Inexact Rounded
! clam193 apply   -1.00000000001e-398     -> #8000000000000001  Subnormal Underflow Inexact Rounded
! clam194 apply   -1.00000000000001e-398  -> #8000000000000001  Subnormal Underflow Inexact Rounded
! clam195 apply   -1.000000000000001e-398 -> #8000000000000001  Subnormal Underflow Inexact Rounded
! clam196 apply   -0.1e-398               -> #8000000000000000  Subnormal Underflow Inexact Rounded
! clam197 apply   -0.00000000001e-398     -> #8000000000000000  Subnormal Underflow Inexact Rounded
! clam198 apply   -0.00000000000001e-398  -> #8000000000000000  Subnormal Underflow Inexact Rounded
! clam199 apply   -0.000000000000001e-398 -> #8000000000000000  Subnormal Underflow Inexact Rounded
! 
! -- zeros
! clam401 apply   0E-500                  -> 0E-398  Clamped
! clam402 apply   0E-400                  -> 0E-398  Clamped
! clam403 apply   0E-398                  -> 0E-398
! clam404 apply   0.000000000000000E-383  -> 0E-398
! clam405 apply   0E-2                    ->  0.00
! clam406 apply   0                       -> 0
! clam407 apply   0E+3                    -> 0E+3
! clam408 apply   0E+369                  -> 0E+369
! -- clamped zeros...
! clam410 apply   0E+370                  -> 0E+369 Clamped
! clam411 apply   0E+384                  -> 0E+369 Clamped
! clam412 apply   0E+400                  -> 0E+369 Clamped
! clam413 apply   0E+500                  -> 0E+369 Clamped
! 
! -- negative zeros
! clam420 apply   -0E-500                 -> -0E-398 Clamped
! clam421 apply   -0E-400                 -> -0E-398 Clamped
! clam422 apply   -0E-398                 -> -0E-398
! clam423 apply   -0.000000000000000E-383 -> -0E-398
! clam424 apply   -0E-2                   -> -0.00
! clam425 apply   -0                      -> -0
! clam426 apply   -0E+3                   -> -0E+3
! clam427 apply   -0E+369                 -> -0E+369
! -- clamped zeros...
! clam431 apply   -0E+370                 -> -0E+369 Clamped
! clam432 apply   -0E+384                 -> -0E+369 Clamped
! clam433 apply   -0E+400                 -> -0E+369 Clamped
! clam434 apply   -0E+500                 -> -0E+369 Clamped
! 
! -- fold-down full sequence
! clam601 apply   1E+384                  -> 1.000000000000000E+384 Clamped
! clam603 apply   1E+383                  -> 1.00000000000000E+383 Clamped
! clam605 apply   1E+382                  -> 1.0000000000000E+382 Clamped
! clam607 apply   1E+381                  -> 1.000000000000E+381 Clamped
! clam609 apply   1E+380                  -> 1.00000000000E+380 Clamped
! clam611 apply   1E+379                  -> 1.0000000000E+379 Clamped
! clam613 apply   1E+378                  -> 1.000000000E+378 Clamped
! clam615 apply   1E+377                  -> 1.00000000E+377 Clamped
! clam617 apply   1E+376                  -> 1.0000000E+376 Clamped
! clam619 apply   1E+375                  -> 1.000000E+375 Clamped
! clam621 apply   1E+374                  -> 1.00000E+374 Clamped
! clam623 apply   1E+373                  -> 1.0000E+373 Clamped
! clam625 apply   1E+372                  -> 1.000E+372 Clamped
! clam627 apply   1E+371                  -> 1.00E+371 Clamped
! clam629 apply   1E+370                  -> 1.0E+370 Clamped
! clam631 apply   1E+369                  -> 1E+369
! clam633 apply   1E+368                  -> 1E+368
! -- same with 9s
! clam641 apply   9E+384                  -> 9.000000000000000E+384 Clamped
! clam643 apply   9E+383                  -> 9.00000000000000E+383 Clamped
! clam645 apply   9E+382                  -> 9.0000000000000E+382 Clamped
! clam647 apply   9E+381                  -> 9.000000000000E+381 Clamped
! clam649 apply   9E+380                  -> 9.00000000000E+380 Clamped
! clam651 apply   9E+379                  -> 9.0000000000E+379 Clamped
! clam653 apply   9E+378                  -> 9.000000000E+378 Clamped
! clam655 apply   9E+377                  -> 9.00000000E+377 Clamped
! clam657 apply   9E+376                  -> 9.0000000E+376 Clamped
! clam659 apply   9E+375                  -> 9.000000E+375 Clamped
! clam661 apply   9E+374                  -> 9.00000E+374 Clamped
! clam663 apply   9E+373                  -> 9.0000E+373 Clamped
! clam665 apply   9E+372                  -> 9.000E+372 Clamped
! clam667 apply   9E+371                  -> 9.00E+371 Clamped
! clam669 apply   9E+370                  -> 9.0E+370 Clamped
! clam671 apply   9E+369                  -> 9E+369
! clam673 apply   9E+368                  -> 9E+368
! 
! -- example from documentation
! precision:   7
! rounding:    half_even
! maxExponent: +96
! minExponent: -95
! 
! clamp:       0
! clam700 apply   1.23E+96                -> 1.23E+96
! 
! clamp:       1
! clam701 apply   1.23E+96                -> 1.230000E+96 Clamped
--- 1,197 ----
! ------------------------------------------------------------------------
! -- clamp.decTest -- clamped exponent tests (format-independent)       --
! -- Copyright (c) IBM Corporation, 2000, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.38
! 
! -- This set of tests uses the same limits as the 8-byte concrete
! -- representation, but applies clamping without using format-specific
! -- conversions.
! 
! extended:    1
! precision:   16
! rounding:    half_even
! maxExponent: 384
! minExponent: -383
! clamp:       1
! 
! -- General testcases
! 
! -- Normality
! clam010 apply   1234567890123456   ->  1234567890123456
! clam011 apply   1234567890123456.0 ->  1234567890123456 Rounded
! clam012 apply   1234567890123456.1 ->  1234567890123456 Rounded Inexact
! clam013 apply  -1234567890123456   -> -1234567890123456
! clam014 apply  -1234567890123456.0 -> -1234567890123456 Rounded
! clam015 apply  -1234567890123456.1 -> -1234567890123456 Rounded Inexact
! 
! 
! -- Nmax and similar
! clam022 apply   9.999999999999999E+384  -> 9.999999999999999E+384
! clam024 apply   1.234567890123456E+384  -> 1.234567890123456E+384
! -- fold-downs (more below)
! clam030 apply   1.23E+384               -> 1.230000000000000E+384 Clamped
! clam032 apply   1E+384                  -> 1.000000000000000E+384 Clamped
! 
! clam051 apply   12345                   -> 12345
! clam053 apply   1234                    -> 1234
! clam055 apply   123                     -> 123
! clam057 apply   12                      -> 12
! clam059 apply   1                       -> 1
! clam061 apply   1.23                    -> 1.23
! clam063 apply   123.45                  -> 123.45
! 
! -- Nmin and below
! clam071 apply   1E-383                  -> 1E-383
! clam073 apply   1.000000000000000E-383  -> 1.000000000000000E-383
! clam075 apply   1.000000000000001E-383  -> 1.000000000000001E-383
! 
! clam077 apply   0.100000000000000E-383  -> 1.00000000000000E-384  Subnormal
! clam079 apply   0.000000000000010E-383  -> 1.0E-397               Subnormal
! clam081 apply   0.00000000000001E-383   -> 1E-397                 Subnormal
! clam083 apply   0.000000000000001E-383  -> 1E-398                 Subnormal
! 
! -- underflows
! clam090 apply   1e-398                  -> #0000000000000001  Subnormal
! clam091 apply   1.9e-398                -> #0000000000000002  Subnormal Underflow Inexact Rounded
! clam092 apply   1.1e-398                -> #0000000000000001  Subnormal Underflow Inexact Rounded
! clam093 apply   1.00000000001e-398      -> #0000000000000001  Subnormal Underflow Inexact Rounded
! clam094 apply   1.00000000000001e-398   -> #0000000000000001  Subnormal Underflow Inexact Rounded
! clam095 apply   1.000000000000001e-398  -> #0000000000000001  Subnormal Underflow Inexact Rounded
! clam096 apply   0.1e-398                -> #0000000000000000  Subnormal Underflow Inexact Rounded
! clam097 apply   0.00000000001e-398      -> #0000000000000000  Subnormal Underflow Inexact Rounded
! clam098 apply   0.00000000000001e-398   -> #0000000000000000  Subnormal Underflow Inexact Rounded
! clam099 apply   0.000000000000001e-398  -> #0000000000000000  Subnormal Underflow Inexact Rounded
! 
! -- Same again, negatives
! -- Nmax and similar
! clam122 apply  -9.999999999999999E+384  -> -9.999999999999999E+384
! clam124 apply  -1.234567890123456E+384  -> -1.234567890123456E+384
! -- fold-downs (more below)
! clam130 apply  -1.23E+384               -> -1.230000000000000E+384 Clamped
! clam132 apply  -1E+384                  -> -1.000000000000000E+384 Clamped
! 
! clam151 apply  -12345                   -> -12345
! clam153 apply  -1234                    -> -1234
! clam155 apply  -123                     -> -123
! clam157 apply  -12                      -> -12
! clam159 apply  -1                       -> -1
! clam161 apply  -1.23                    -> -1.23
! clam163 apply  -123.45                  -> -123.45
! 
! -- Nmin and below
! clam171 apply  -1E-383                  -> -1E-383
! clam173 apply  -1.000000000000000E-383  -> -1.000000000000000E-383
! clam175 apply  -1.000000000000001E-383  -> -1.000000000000001E-383
! 
! clam177 apply  -0.100000000000000E-383  -> -1.00000000000000E-384  Subnormal
! clam179 apply  -0.000000000000010E-383  -> -1.0E-397               Subnormal
! clam181 apply  -0.00000000000001E-383   -> -1E-397                 Subnormal
! clam183 apply  -0.000000000000001E-383  -> -1E-398                 Subnormal
! 
! -- underflows
! clam189 apply   -1e-398                 -> #8000000000000001  Subnormal
! clam190 apply   -1.0e-398               -> #8000000000000001  Subnormal Rounded
! clam191 apply   -1.9e-398               -> #8000000000000002  Subnormal Underflow Inexact Rounded
! clam192 apply   -1.1e-398               -> #8000000000000001  Subnormal Underflow Inexact Rounded
! clam193 apply   -1.00000000001e-398     -> #8000000000000001  Subnormal Underflow Inexact Rounded
! clam194 apply   -1.00000000000001e-398  -> #8000000000000001  Subnormal Underflow Inexact Rounded
! clam195 apply   -1.000000000000001e-398 -> #8000000000000001  Subnormal Underflow Inexact Rounded
! clam196 apply   -0.1e-398               -> #8000000000000000  Subnormal Underflow Inexact Rounded
! clam197 apply   -0.00000000001e-398     -> #8000000000000000  Subnormal Underflow Inexact Rounded
! clam198 apply   -0.00000000000001e-398  -> #8000000000000000  Subnormal Underflow Inexact Rounded
! clam199 apply   -0.000000000000001e-398 -> #8000000000000000  Subnormal Underflow Inexact Rounded
! 
! -- zeros
! clam401 apply   0E-500                  -> 0E-398  Clamped
! clam402 apply   0E-400                  -> 0E-398  Clamped
! clam403 apply   0E-398                  -> 0E-398
! clam404 apply   0.000000000000000E-383  -> 0E-398
! clam405 apply   0E-2                    ->  0.00
! clam406 apply   0                       -> 0
! clam407 apply   0E+3                    -> 0E+3
! clam408 apply   0E+369                  -> 0E+369
! -- clamped zeros...
! clam410 apply   0E+370                  -> 0E+369 Clamped
! clam411 apply   0E+384                  -> 0E+369 Clamped
! clam412 apply   0E+400                  -> 0E+369 Clamped
! clam413 apply   0E+500                  -> 0E+369 Clamped
! 
! -- negative zeros
! clam420 apply   -0E-500                 -> -0E-398 Clamped
! clam421 apply   -0E-400                 -> -0E-398 Clamped
! clam422 apply   -0E-398                 -> -0E-398
! clam423 apply   -0.000000000000000E-383 -> -0E-398
! clam424 apply   -0E-2                   -> -0.00
! clam425 apply   -0                      -> -0
! clam426 apply   -0E+3                   -> -0E+3
! clam427 apply   -0E+369                 -> -0E+369
! -- clamped zeros...
! clam431 apply   -0E+370                 -> -0E+369 Clamped
! clam432 apply   -0E+384                 -> -0E+369 Clamped
! clam433 apply   -0E+400                 -> -0E+369 Clamped
! clam434 apply   -0E+500                 -> -0E+369 Clamped
! 
! -- fold-down full sequence
! clam601 apply   1E+384                  -> 1.000000000000000E+384 Clamped
! clam603 apply   1E+383                  -> 1.00000000000000E+383 Clamped
! clam605 apply   1E+382                  -> 1.0000000000000E+382 Clamped
! clam607 apply   1E+381                  -> 1.000000000000E+381 Clamped
! clam609 apply   1E+380                  -> 1.00000000000E+380 Clamped
! clam611 apply   1E+379                  -> 1.0000000000E+379 Clamped
! clam613 apply   1E+378                  -> 1.000000000E+378 Clamped
! clam615 apply   1E+377                  -> 1.00000000E+377 Clamped
! clam617 apply   1E+376                  -> 1.0000000E+376 Clamped
! clam619 apply   1E+375                  -> 1.000000E+375 Clamped
! clam621 apply   1E+374                  -> 1.00000E+374 Clamped
! clam623 apply   1E+373                  -> 1.0000E+373 Clamped
! clam625 apply   1E+372                  -> 1.000E+372 Clamped
! clam627 apply   1E+371                  -> 1.00E+371 Clamped
! clam629 apply   1E+370                  -> 1.0E+370 Clamped
! clam631 apply   1E+369                  -> 1E+369
! clam633 apply   1E+368                  -> 1E+368
! -- same with 9s
! clam641 apply   9E+384                  -> 9.000000000000000E+384 Clamped
! clam643 apply   9E+383                  -> 9.00000000000000E+383 Clamped
! clam645 apply   9E+382                  -> 9.0000000000000E+382 Clamped
! clam647 apply   9E+381                  -> 9.000000000000E+381 Clamped
! clam649 apply   9E+380                  -> 9.00000000000E+380 Clamped
! clam651 apply   9E+379                  -> 9.0000000000E+379 Clamped
! clam653 apply   9E+378                  -> 9.000000000E+378 Clamped
! clam655 apply   9E+377                  -> 9.00000000E+377 Clamped
! clam657 apply   9E+376                  -> 9.0000000E+376 Clamped
! clam659 apply   9E+375                  -> 9.000000E+375 Clamped
! clam661 apply   9E+374                  -> 9.00000E+374 Clamped
! clam663 apply   9E+373                  -> 9.0000E+373 Clamped
! clam665 apply   9E+372                  -> 9.000E+372 Clamped
! clam667 apply   9E+371                  -> 9.00E+371 Clamped
! clam669 apply   9E+370                  -> 9.0E+370 Clamped
! clam671 apply   9E+369                  -> 9E+369
! clam673 apply   9E+368                  -> 9E+368
! 
! -- example from documentation
! precision:   7
! rounding:    half_even
! maxExponent: +96
! minExponent: -95
! 
! clamp:       0
! clam700 apply   1.23E+96                -> 1.23E+96
! 
! clamp:       1
! clam701 apply   1.23E+96                -> 1.230000E+96 Clamped

Index: compare.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/compare.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** compare.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- compare.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,717 ****
! ------------------------------------------------------------------------
! -- compare.decTest -- decimal comparison                              --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
[...1405 lines suppressed...]
! comx894 compare 0.01 9e-999999998           ->  1
! comx895 compare 1e599999999 1e400000001     ->  1
! comx896 compare 1e599999999 1e400000000     ->  1
! comx897 compare 1e600000000 1e400000000     ->  1
! comx898 compare 9e999999998 100             ->  1
! comx899 compare 9e999999998 10              ->  1
! comx900 compare 100  9e999999998            -> -1
! -- signs
! comx901 compare  1e+777777777  1e+411111111 ->  1
! comx902 compare  1e+777777777 -1e+411111111 ->  1
! comx903 compare -1e+777777777  1e+411111111 -> -1
! comx904 compare -1e+777777777 -1e+411111111 -> -1
! comx905 compare  1e-777777777  1e-411111111 -> -1
! comx906 compare  1e-777777777 -1e-411111111 ->  1
! comx907 compare -1e-777777777  1e-411111111 -> -1
! comx908 compare -1e-777777777 -1e-411111111 ->  1
! 
! -- Null tests
! comx990 compare 10  # -> NaN Invalid_operation
! comx991 compare  # 10 -> NaN Invalid_operation

Index: divide.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/divide.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** divide.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- divide.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,818 ****
! ------------------------------------------------------------------------
! -- divide.decTest -- decimal division                                 --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
[...1607 lines suppressed...]
! precision:   5
! maxexponent: 79
! minexponent: -79
! divx1001 divide    1.52444E-80 1      -> 1.524E-80 Inexact Rounded Subnormal Underflow
! divx1002 divide    1.52445E-80 1      -> 1.524E-80 Inexact Rounded Subnormal Underflow
! divx1003 divide    1.52446E-80 1      -> 1.524E-80 Inexact Rounded Subnormal Underflow
! 
! -- a rounding problem in one implementation
! precision:   34
! rounding:    half_up
! maxExponent: 6144
! minExponent: -6143
! -- Unbounded answer to 40 digits:
! --   1.465811965811965811965811965811965811966E+7000
! divx1010 divide 343E6000  234E-1000 -> Infinity Overflow Inexact Rounded
! 
! -- Null tests
! divx9998 divide 10  # -> NaN Invalid_operation
! divx9999 divide  # 10 -> NaN Invalid_operation
! 

Index: divideint.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/divideint.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** divideint.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- divideint.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,470 ****
! ------------------------------------------------------------------------
! -- divideint.decTest -- decimal integer division                      --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.35
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minexponent: -999
! 
! dvix001 divideint  1     1    ->  1
! dvix002 divideint  2     1    ->  2
! dvix003 divideint  1     2    ->  0
! dvix004 divideint  2     2    ->  1
! dvix005 divideint  0     1    ->  0
! dvix006 divideint  0     2    ->  0
! dvix007 divideint  1     3    ->  0
! dvix008 divideint  2     3    ->  0
! dvix009 divideint  3     3    ->  1
! 
! dvix010 divideint  2.4   1    ->  2
! dvix011 divideint  2.4   -1   ->  -2
! dvix012 divideint  -2.4  1    ->  -2
! dvix013 divideint  -2.4  -1   ->  2
! dvix014 divideint  2.40  1    ->  2
! dvix015 divideint  2.400 1    ->  2
! dvix016 divideint  2.4   2    ->  1
! dvix017 divideint  2.400 2    ->  1
! dvix018 divideint  2.    2    ->  1
! dvix019 divideint  20    20   ->  1
! 
! dvix020 divideint  187   187  ->  1
! dvix021 divideint  5     2    ->  2
! dvix022 divideint  5     2.0    ->  2
! dvix023 divideint  5     2.000  ->  2
! dvix024 divideint  5     0.200  ->  25
! dvix025 divideint  5     0.200  ->  25
! 
! dvix030 divideint  1     2      ->  0
! dvix031 divideint  1     4      ->  0
! dvix032 divideint  1     8      ->  0
! dvix033 divideint  1     16     ->  0
! dvix034 divideint  1     32     ->  0
! dvix035 divideint  1     64     ->  0
! dvix040 divideint  1    -2      -> -0
! dvix041 divideint  1    -4      -> -0
! dvix042 divideint  1    -8      -> -0
! dvix043 divideint  1    -16     -> -0
! dvix044 divideint  1    -32     -> -0
! dvix045 divideint  1    -64     -> -0
! dvix050 divideint -1     2      -> -0
! dvix051 divideint -1     4      -> -0
! dvix052 divideint -1     8      -> -0
! dvix053 divideint -1     16     -> -0
! dvix054 divideint -1     32     -> -0
! dvix055 divideint -1     64     -> -0
! dvix060 divideint -1    -2      ->  0
! dvix061 divideint -1    -4      ->  0
! dvix062 divideint -1    -8      ->  0
! dvix063 divideint -1    -16     ->  0
! dvix064 divideint -1    -32     ->  0
! dvix065 divideint -1    -64     ->  0
! 
! -- similar with powers of ten
! dvix160 divideint  1     1         ->  1
! dvix161 divideint  1     10        ->  0
! dvix162 divideint  1     100       ->  0
! dvix163 divideint  1     1000      ->  0
! dvix164 divideint  1     10000     ->  0
! dvix165 divideint  1     100000    ->  0
! dvix166 divideint  1     1000000   ->  0
! dvix167 divideint  1     10000000  ->  0
! dvix168 divideint  1     100000000 ->  0
! dvix170 divideint  1    -1         -> -1
! dvix171 divideint  1    -10        -> -0
! dvix172 divideint  1    -100       -> -0
! dvix173 divideint  1    -1000      -> -0
! dvix174 divideint  1    -10000     -> -0
! dvix175 divideint  1    -100000    -> -0
! dvix176 divideint  1    -1000000   -> -0
! dvix177 divideint  1    -10000000  -> -0
! dvix178 divideint  1    -100000000 -> -0
! dvix180 divideint -1     1         -> -1
! dvix181 divideint -1     10        -> -0
! dvix182 divideint -1     100       -> -0
! dvix183 divideint -1     1000      -> -0
! dvix184 divideint -1     10000     -> -0
! dvix185 divideint -1     100000    -> -0
! dvix186 divideint -1     1000000   -> -0
! dvix187 divideint -1     10000000  -> -0
! dvix188 divideint -1     100000000 -> -0
! dvix190 divideint -1    -1         ->  1
! dvix191 divideint -1    -10        ->  0
! dvix192 divideint -1    -100       ->  0
! dvix193 divideint -1    -1000      ->  0
! dvix194 divideint -1    -10000     ->  0
! dvix195 divideint -1    -100000    ->  0
! dvix196 divideint -1    -1000000   ->  0
! dvix197 divideint -1    -10000000  ->  0
! dvix198 divideint -1    -100000000 ->  0
! 
! -- some long operand cases here
! dvix070 divideint  999999999     1  ->  999999999
! dvix071 divideint  999999999.4   1  ->  999999999
! dvix072 divideint  999999999.5   1  ->  999999999
! dvix073 divideint  999999999.9   1  ->  999999999
! dvix074 divideint  999999999.999 1  ->  999999999
! precision: 6
! dvix080 divideint  999999999     1  ->  NaN Division_impossible
! dvix081 divideint  99999999      1  ->  NaN Division_impossible
! dvix082 divideint  9999999       1  ->  NaN Division_impossible
! dvix083 divideint  999999        1  ->  999999
! dvix084 divideint  99999         1  ->  99999
! dvix085 divideint  9999          1  ->  9999
! dvix086 divideint  999           1  ->  999
! dvix087 divideint  99            1  ->  99
! dvix088 divideint  9             1  ->  9
! 
! precision: 9
! dvix090 divideint  0.            1    ->  0
! dvix091 divideint  .0            1    ->  0
! dvix092 divideint  0.00          1    ->  0
! dvix093 divideint  0.00E+9       1    ->  0
! dvix094 divideint  0.0000E-50    1    ->  0
! 
! dvix100 divideint  1  1   -> 1
! dvix101 divideint  1  2   -> 0
! dvix102 divideint  1  3   -> 0
! dvix103 divideint  1  4   -> 0
! dvix104 divideint  1  5   -> 0
! dvix105 divideint  1  6   -> 0
! dvix106 divideint  1  7   -> 0
! dvix107 divideint  1  8   -> 0
! dvix108 divideint  1  9   -> 0
! dvix109 divideint  1  10  -> 0
! dvix110 divideint  1  1   -> 1
! dvix111 divideint  2  1   -> 2
! dvix112 divideint  3  1   -> 3
! dvix113 divideint  4  1   -> 4
! dvix114 divideint  5  1   -> 5
! dvix115 divideint  6  1   -> 6
! dvix116 divideint  7  1   -> 7
! dvix117 divideint  8  1   -> 8
! dvix118 divideint  9  1   -> 9
! dvix119 divideint  10 1   -> 10
! 
! -- from DiagBigDecimal
! dvix131 divideint  101.3   1     ->  101
! dvix132 divideint  101.0   1     ->  101
! dvix133 divideint  101.3   3     ->  33
! dvix134 divideint  101.0   3     ->  33
! dvix135 divideint  2.4     1     ->  2
! dvix136 divideint  2.400   1     ->  2
! dvix137 divideint  18      18    ->  1
! dvix138 divideint  1120    1000  ->  1
! dvix139 divideint  2.4     2     ->  1
! dvix140 divideint  2.400   2     ->  1
! dvix141 divideint  0.5     2.000 ->  0
! dvix142 divideint  8.005   7     ->  1
! dvix143 divideint  5       2     ->  2
! dvix144 divideint  0       2     ->  0
! dvix145 divideint  0.00    2     ->  0
! 
! -- Others
! dvix150 divideint  12345  4.999  ->  2469
! dvix151 divideint  12345  4.99   ->  2473
! dvix152 divideint  12345  4.9    ->  2519
! dvix153 divideint  12345  5      ->  2469
! dvix154 divideint  12345  5.1    ->  2420
! dvix155 divideint  12345  5.01   ->  2464
! dvix156 divideint  12345  5.001  ->  2468
! dvix157 divideint    101  7.6    ->  13
! 
! -- Various flavours of divideint by 0
! maxexponent: 999999999
! minexponent: -999999999
! dvix201 divideint  0      0   -> NaN Division_undefined
! dvix202 divideint  0.0E5  0   -> NaN Division_undefined
! dvix203 divideint  0.000  0   -> NaN Division_undefined
! dvix204 divideint  0.0001 0   -> Infinity Division_by_zero
! dvix205 divideint  0.01   0   -> Infinity Division_by_zero
! dvix206 divideint  0.1    0   -> Infinity Division_by_zero
! dvix207 divideint  1      0   -> Infinity Division_by_zero
! dvix208 divideint  1      0.0 -> Infinity Division_by_zero
! dvix209 divideint 10      0.0 -> Infinity Division_by_zero
! dvix210 divideint 1E+100  0.0 -> Infinity Division_by_zero
! dvix211 divideint 1E+1000 0   -> Infinity Division_by_zero
! dvix214 divideint  -0.0001 0   -> -Infinity Division_by_zero
! dvix215 divideint  -0.01   0   -> -Infinity Division_by_zero
! dvix216 divideint  -0.1    0   -> -Infinity Division_by_zero
! dvix217 divideint  -1      0   -> -Infinity Division_by_zero
! dvix218 divideint  -1      0.0 -> -Infinity Division_by_zero
! dvix219 divideint -10      0.0 -> -Infinity Division_by_zero
! dvix220 divideint -1E+100  0.0 -> -Infinity Division_by_zero
! dvix221 divideint -1E+1000 0   -> -Infinity Division_by_zero
! 
! -- test some cases that are close to exponent overflow
! maxexponent: 999999999
! minexponent: -999999999
! dvix270 divideint 1 1e999999999    -> 0
! dvix271 divideint 1 0.9e999999999  -> 0
! dvix272 divideint 1 0.99e999999999 -> 0
! dvix273 divideint 1 0.999999999e999999999 -> 0
! dvix274 divideint 9e999999999    1       -> NaN Division_impossible
! dvix275 divideint 9.9e999999999  1       -> NaN Division_impossible
! dvix276 divideint 9.99e999999999 1       -> NaN Division_impossible
! dvix277 divideint 9.99999999e999999999 1 -> NaN Division_impossible
! 
! dvix280 divideint 0.1 9e-999999999       -> NaN Division_impossible
! dvix281 divideint 0.1 99e-999999999      -> NaN Division_impossible
! dvix282 divideint 0.1 999e-999999999     -> NaN Division_impossible
! 
! dvix283 divideint 0.1 9e-999999998       -> NaN Division_impossible
! dvix284 divideint 0.1 99e-999999998      -> NaN Division_impossible
! dvix285 divideint 0.1 999e-999999998     -> NaN Division_impossible
! dvix286 divideint 0.1 999e-999999997     -> NaN Division_impossible
! dvix287 divideint 0.1 9999e-999999997    -> NaN Division_impossible
! dvix288 divideint 0.1 99999e-999999997   -> NaN Division_impossible
! 
! 
! -- overflow and underflow tests [from divide]
! maxexponent: 999999999
! minexponent: -999999999
! dvix330 divideint +1.23456789012345E-0 9E+999999999    -> 0
! dvix331 divideint 9E+999999999 +0.23456789012345E-0 -> NaN Division_impossible
! dvix332 divideint +0.100 9E+999999999    -> 0
! dvix333 divideint 9E-999999999 +9.100    -> 0
! dvix335 divideint -1.23456789012345E-0 9E+999999999    -> -0
! dvix336 divideint 9E+999999999 -0.83456789012345E-0 -> NaN Division_impossible
! dvix337 divideint -0.100 9E+999999999    -> -0
! dvix338 divideint 9E-999999999 -9.100    -> -0
! 
! -- long operand checks
! maxexponent: 999
! minexponent: -999
! precision: 9
! dvix401 divideint 12345678000 100 -> 123456780
! dvix402 divideint 1 12345678000   -> 0
! dvix403 divideint 1234567800  10  -> 123456780
! dvix404 divideint 1 1234567800    -> 0
! dvix405 divideint 1234567890  10  -> 123456789
! dvix406 divideint 1 1234567890    -> 0
! dvix407 divideint 1234567891  10  -> 123456789
! dvix408 divideint 1 1234567891    -> 0
! dvix409 divideint 12345678901 100 -> 123456789
! dvix410 divideint 1 12345678901   -> 0
! dvix411 divideint 1234567896  10  -> 123456789
! dvix412 divideint 1 1234567896    -> 0
! dvix413 divideint 12345678948 100 -> 123456789
! dvix414 divideint 12345678949 100 -> 123456789
! dvix415 divideint 12345678950 100 -> 123456789
! dvix416 divideint 12345678951 100 -> 123456789
! dvix417 divideint 12345678999 100 -> 123456789
! 
! precision: 15
! dvix441 divideint 12345678000 1 -> 12345678000
! dvix442 divideint 1 12345678000 -> 0
! dvix443 divideint 1234567800  1 -> 1234567800
! dvix444 divideint 1 1234567800  -> 0
! dvix445 divideint 1234567890  1 -> 1234567890
! dvix446 divideint 1 1234567890  -> 0
! dvix447 divideint 1234567891  1 -> 1234567891
! dvix448 divideint 1 1234567891  -> 0
! dvix449 divideint 12345678901 1 -> 12345678901
! dvix450 divideint 1 12345678901 -> 0
! dvix451 divideint 1234567896  1 -> 1234567896
! dvix452 divideint 1 1234567896  -> 0
! 
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minexponent: -999
! 
! -- more zeros, etc.
! dvix531 divideint 5.00 1E-3    -> 5000
! dvix532 divideint 00.00 0.000  -> NaN Division_undefined
! dvix533 divideint 00.00 0E-3   -> NaN Division_undefined
! dvix534 divideint  0    -0     -> NaN Division_undefined
! dvix535 divideint -0     0     -> NaN Division_undefined
! dvix536 divideint -0    -0     -> NaN Division_undefined
! 
! dvix541 divideint  0    -1     -> -0
! dvix542 divideint -0    -1     ->  0
! dvix543 divideint  0     1     ->  0
! dvix544 divideint -0     1     -> -0
! dvix545 divideint -1     0     -> -Infinity Division_by_zero
! dvix546 divideint -1    -0     ->  Infinity Division_by_zero
! dvix547 divideint  1     0     ->  Infinity Division_by_zero
! dvix548 divideint  1    -0     -> -Infinity Division_by_zero
! 
! dvix551 divideint  0.0  -1     -> -0
! dvix552 divideint -0.0  -1     ->  0
! dvix553 divideint  0.0   1     ->  0
! dvix554 divideint -0.0   1     -> -0
! dvix555 divideint -1.0   0     -> -Infinity Division_by_zero
! dvix556 divideint -1.0  -0     ->  Infinity Division_by_zero
! dvix557 divideint  1.0   0     ->  Infinity Division_by_zero
! dvix558 divideint  1.0  -0     -> -Infinity Division_by_zero
! 
! dvix561 divideint  0    -1.0   -> -0
! dvix562 divideint -0    -1.0   ->  0
! dvix563 divideint  0     1.0   ->  0
! dvix564 divideint -0     1.0   -> -0
! dvix565 divideint -1     0.0   -> -Infinity Division_by_zero
! dvix566 divideint -1    -0.0   ->  Infinity Division_by_zero
! dvix567 divideint  1     0.0   ->  Infinity Division_by_zero
! dvix568 divideint  1    -0.0   -> -Infinity Division_by_zero
! 
! dvix571 divideint  0.0  -1.0   -> -0
! dvix572 divideint -0.0  -1.0   ->  0
! dvix573 divideint  0.0   1.0   ->  0
! dvix574 divideint -0.0   1.0   -> -0
! dvix575 divideint -1.0   0.0   -> -Infinity Division_by_zero
! dvix576 divideint -1.0  -0.0   ->  Infinity Division_by_zero
! dvix577 divideint  1.0   0.0   ->  Infinity Division_by_zero
! dvix578 divideint  1.0  -0.0   -> -Infinity Division_by_zero
! 
! -- Specials
! dvix580 divideint  Inf  -Inf   ->  NaN Invalid_operation
! dvix581 divideint  Inf  -1000  -> -Infinity
! dvix582 divideint  Inf  -1     -> -Infinity
! dvix583 divideint  Inf  -0     -> -Infinity
! dvix584 divideint  Inf   0     ->  Infinity
! dvix585 divideint  Inf   1     ->  Infinity
! dvix586 divideint  Inf   1000  ->  Infinity
! dvix587 divideint  Inf   Inf   ->  NaN Invalid_operation
! dvix588 divideint -1000  Inf   -> -0
! dvix589 divideint -Inf   Inf   ->  NaN Invalid_operation
! dvix590 divideint -1     Inf   -> -0
! dvix591 divideint -0     Inf   -> -0
! dvix592 divideint  0     Inf   ->  0
! dvix593 divideint  1     Inf   ->  0
! dvix594 divideint  1000  Inf   ->  0
! dvix595 divideint  Inf   Inf   ->  NaN Invalid_operation
! 
! dvix600 divideint -Inf  -Inf   ->  NaN Invalid_operation
! dvix601 divideint -Inf  -1000  ->  Infinity
! dvix602 divideint -Inf  -1     ->  Infinity
! dvix603 divideint -Inf  -0     ->  Infinity
! dvix604 divideint -Inf   0     -> -Infinity
! dvix605 divideint -Inf   1     -> -Infinity
! dvix606 divideint -Inf   1000  -> -Infinity
! dvix607 divideint -Inf   Inf   ->  NaN Invalid_operation
! dvix608 divideint -1000  Inf   -> -0
! dvix609 divideint -Inf  -Inf   ->  NaN Invalid_operation
! dvix610 divideint -1    -Inf   ->  0
! dvix611 divideint -0    -Inf   ->  0
! dvix612 divideint  0    -Inf   -> -0
! dvix613 divideint  1    -Inf   -> -0
! dvix614 divideint  1000 -Inf   -> -0
! dvix615 divideint  Inf  -Inf   ->  NaN Invalid_operation
! 
! dvix621 divideint  NaN -Inf    ->  NaN
! dvix622 divideint  NaN -1000   ->  NaN
! dvix623 divideint  NaN -1      ->  NaN
! dvix624 divideint  NaN -0      ->  NaN
! dvix625 divideint  NaN  0      ->  NaN
! dvix626 divideint  NaN  1      ->  NaN
! dvix627 divideint  NaN  1000   ->  NaN
! dvix628 divideint  NaN  Inf    ->  NaN
! dvix629 divideint  NaN  NaN    ->  NaN
! dvix630 divideint -Inf  NaN    ->  NaN
! dvix631 divideint -1000 NaN    ->  NaN
! dvix632 divideint -1    NaN    ->  NaN
! dvix633 divideint -0    NaN    ->  NaN
! dvix634 divideint  0    NaN    ->  NaN
! dvix635 divideint  1    NaN    ->  NaN
! dvix636 divideint  1000 NaN    ->  NaN
! dvix637 divideint  Inf  NaN    ->  NaN
! 
! dvix641 divideint  sNaN -Inf   ->  NaN  Invalid_operation
! dvix642 divideint  sNaN -1000  ->  NaN  Invalid_operation
! dvix643 divideint  sNaN -1     ->  NaN  Invalid_operation
! dvix644 divideint  sNaN -0     ->  NaN  Invalid_operation
! dvix645 divideint  sNaN  0     ->  NaN  Invalid_operation
! dvix646 divideint  sNaN  1     ->  NaN  Invalid_operation
! dvix647 divideint  sNaN  1000  ->  NaN  Invalid_operation
! dvix648 divideint  sNaN  NaN   ->  NaN  Invalid_operation
! dvix649 divideint  sNaN sNaN   ->  NaN  Invalid_operation
! dvix650 divideint  NaN  sNaN   ->  NaN  Invalid_operation
! dvix651 divideint -Inf  sNaN   ->  NaN  Invalid_operation
! dvix652 divideint -1000 sNaN   ->  NaN  Invalid_operation
! dvix653 divideint -1    sNaN   ->  NaN  Invalid_operation
! dvix654 divideint -0    sNaN   ->  NaN  Invalid_operation
! dvix655 divideint  0    sNaN   ->  NaN  Invalid_operation
! dvix656 divideint  1    sNaN   ->  NaN  Invalid_operation
! dvix657 divideint  1000 sNaN   ->  NaN  Invalid_operation
! dvix658 divideint  Inf  sNaN   ->  NaN  Invalid_operation
! dvix659 divideint  NaN  sNaN   ->  NaN  Invalid_operation
! 
! -- propagating NaNs
! dvix661 divideint  NaN9 -Inf   ->  NaN9
! dvix662 divideint  NaN8  1000  ->  NaN8
! dvix663 divideint  NaN7  Inf   ->  NaN7
! dvix664 divideint -NaN6  NaN5  -> -NaN6
! dvix665 divideint -Inf   NaN4  ->  NaN4
! dvix666 divideint -1000  NaN3  ->  NaN3
! dvix667 divideint  Inf  -NaN2  -> -NaN2
! 
! dvix671 divideint -sNaN99 -Inf    -> -NaN99 Invalid_operation
! dvix672 divideint  sNaN98 -1      ->  NaN98 Invalid_operation
! dvix673 divideint  sNaN97  NaN    ->  NaN97 Invalid_operation
! dvix674 divideint  sNaN96 sNaN94  ->  NaN96 Invalid_operation
! dvix675 divideint  NaN95  sNaN93  ->  NaN93 Invalid_operation
! dvix676 divideint -Inf    sNaN92  ->  NaN92 Invalid_operation
! dvix677 divideint  0      sNaN91  ->  NaN91 Invalid_operation
! dvix678 divideint  Inf   -sNaN90  -> -NaN90 Invalid_operation
! dvix679 divideint  NaN    sNaN89  ->  NaN89 Invalid_operation
! 
! -- some long operand cases again
! precision: 8
! dvix710 divideint  100000001     1  ->  NaN Division_impossible
! dvix711 divideint  100000000.4   1  ->  NaN Division_impossible
! dvix712 divideint  100000000.5   1  ->  NaN Division_impossible
! dvix713 divideint  100000000.9   1  ->  NaN Division_impossible
! dvix714 divideint  100000000.999 1  ->  NaN Division_impossible
! precision: 6
! dvix720 divideint  100000000     1  ->  NaN Division_impossible
! dvix721 divideint  10000000      1  ->  NaN Division_impossible
! dvix722 divideint  1000000       1  ->  NaN Division_impossible
! dvix723 divideint  100000        1  ->  100000
! dvix724 divideint  10000         1  ->  10000
! dvix725 divideint  1000          1  ->  1000
! dvix726 divideint  100           1  ->  100
! dvix727 divideint  10            1  ->  10
! dvix728 divideint  1             1  ->  1
! dvix729 divideint  1            10  ->  0
! 
! precision: 9
! maxexponent: 999999999
! minexponent: -999999999
! dvix732 divideint 1 0.99e999999999 -> 0
! dvix733 divideint 1 0.999999999e999999999 -> 0
! dvix734 divideint 9e999999999    1       -> NaN Division_impossible
! dvix735 divideint 9.9e999999999  1       -> NaN Division_impossible
! dvix736 divideint 9.99e999999999 1       -> NaN Division_impossible
! dvix737 divideint 9.99999999e999999999 1 -> NaN Division_impossible
! 
! dvix740 divideint 0.1 9e-999999999       -> NaN Division_impossible
! dvix741 divideint 0.1 99e-999999999      -> NaN Division_impossible
! dvix742 divideint 0.1 999e-999999999     -> NaN Division_impossible
! 
! dvix743 divideint 0.1 9e-999999998       -> NaN Division_impossible
! dvix744 divideint 0.1 99e-999999998      -> NaN Division_impossible
! dvix745 divideint 0.1 999e-999999998     -> NaN Division_impossible
! dvix746 divideint 0.1 999e-999999997     -> NaN Division_impossible
! dvix747 divideint 0.1 9999e-999999997    -> NaN Division_impossible
! dvix748 divideint 0.1 99999e-999999997   -> NaN Division_impossible
! 
! 
! -- Null tests
! dvix900 divideint  10  # -> NaN Invalid_operation
! dvix901 divideint   # 10 -> NaN Invalid_operation
--- 1,470 ----
! ------------------------------------------------------------------------
! -- divideint.decTest -- decimal integer division                      --
! -- Copyright (c) IBM Corporation, 1981, 2004.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.38
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 384
! minexponent: -383
! 
! dvix001 divideint  1     1    ->  1
! dvix002 divideint  2     1    ->  2
! dvix003 divideint  1     2    ->  0
! dvix004 divideint  2     2    ->  1
! dvix005 divideint  0     1    ->  0
! dvix006 divideint  0     2    ->  0
! dvix007 divideint  1     3    ->  0
! dvix008 divideint  2     3    ->  0
! dvix009 divideint  3     3    ->  1
! 
! dvix010 divideint  2.4   1    ->  2
! dvix011 divideint  2.4   -1   ->  -2
! dvix012 divideint  -2.4  1    ->  -2
! dvix013 divideint  -2.4  -1   ->  2
! dvix014 divideint  2.40  1    ->  2
! dvix015 divideint  2.400 1    ->  2
! dvix016 divideint  2.4   2    ->  1
! dvix017 divideint  2.400 2    ->  1
! dvix018 divideint  2.    2    ->  1
! dvix019 divideint  20    20   ->  1
! 
! dvix020 divideint  187   187  ->  1
! dvix021 divideint  5     2    ->  2
! dvix022 divideint  5     2.0    ->  2
! dvix023 divideint  5     2.000  ->  2
! dvix024 divideint  5     0.200  ->  25
! dvix025 divideint  5     0.200  ->  25
! 
! dvix030 divideint  1     2      ->  0
! dvix031 divideint  1     4      ->  0
! dvix032 divideint  1     8      ->  0
! dvix033 divideint  1     16     ->  0
! dvix034 divideint  1     32     ->  0
! dvix035 divideint  1     64     ->  0
! dvix040 divideint  1    -2      -> -0
! dvix041 divideint  1    -4      -> -0
! dvix042 divideint  1    -8      -> -0
! dvix043 divideint  1    -16     -> -0
! dvix044 divideint  1    -32     -> -0
! dvix045 divideint  1    -64     -> -0
! dvix050 divideint -1     2      -> -0
! dvix051 divideint -1     4      -> -0
! dvix052 divideint -1     8      -> -0
! dvix053 divideint -1     16     -> -0
! dvix054 divideint -1     32     -> -0
! dvix055 divideint -1     64     -> -0
! dvix060 divideint -1    -2      ->  0
! dvix061 divideint -1    -4      ->  0
! dvix062 divideint -1    -8      ->  0
! dvix063 divideint -1    -16     ->  0
! dvix064 divideint -1    -32     ->  0
! dvix065 divideint -1    -64     ->  0
! 
! -- similar with powers of ten
! dvix160 divideint  1     1         ->  1
! dvix161 divideint  1     10        ->  0
! dvix162 divideint  1     100       ->  0
! dvix163 divideint  1     1000      ->  0
! dvix164 divideint  1     10000     ->  0
! dvix165 divideint  1     100000    ->  0
! dvix166 divideint  1     1000000   ->  0
! dvix167 divideint  1     10000000  ->  0
! dvix168 divideint  1     100000000 ->  0
! dvix170 divideint  1    -1         -> -1
! dvix171 divideint  1    -10        -> -0
! dvix172 divideint  1    -100       -> -0
! dvix173 divideint  1    -1000      -> -0
! dvix174 divideint  1    -10000     -> -0
! dvix175 divideint  1    -100000    -> -0
! dvix176 divideint  1    -1000000   -> -0
! dvix177 divideint  1    -10000000  -> -0
! dvix178 divideint  1    -100000000 -> -0
! dvix180 divideint -1     1         -> -1
! dvix181 divideint -1     10        -> -0
! dvix182 divideint -1     100       -> -0
! dvix183 divideint -1     1000      -> -0
! dvix184 divideint -1     10000     -> -0
! dvix185 divideint -1     100000    -> -0
! dvix186 divideint -1     1000000   -> -0
! dvix187 divideint -1     10000000  -> -0
! dvix188 divideint -1     100000000 -> -0
! dvix190 divideint -1    -1         ->  1
! dvix191 divideint -1    -10        ->  0
! dvix192 divideint -1    -100       ->  0
! dvix193 divideint -1    -1000      ->  0
! dvix194 divideint -1    -10000     ->  0
! dvix195 divideint -1    -100000    ->  0
! dvix196 divideint -1    -1000000   ->  0
! dvix197 divideint -1    -10000000  ->  0
! dvix198 divideint -1    -100000000 ->  0
! 
! -- some long operand cases here
! dvix070 divideint  999999999     1  ->  999999999
! dvix071 divideint  999999999.4   1  ->  999999999
! dvix072 divideint  999999999.5   1  ->  999999999
! dvix073 divideint  999999999.9   1  ->  999999999
! dvix074 divideint  999999999.999 1  ->  999999999
! precision: 6
! dvix080 divideint  999999999     1  ->  NaN Division_impossible
! dvix081 divideint  99999999      1  ->  NaN Division_impossible
! dvix082 divideint  9999999       1  ->  NaN Division_impossible
! dvix083 divideint  999999        1  ->  999999
! dvix084 divideint  99999         1  ->  99999
! dvix085 divideint  9999          1  ->  9999
! dvix086 divideint  999           1  ->  999
! dvix087 divideint  99            1  ->  99
! dvix088 divideint  9             1  ->  9
! 
! precision: 9
! dvix090 divideint  0.            1    ->  0
! dvix091 divideint  .0            1    ->  0
! dvix092 divideint  0.00          1    ->  0
! dvix093 divideint  0.00E+9       1    ->  0
! dvix094 divideint  0.0000E-50    1    ->  0
! 
! dvix100 divideint  1  1   -> 1
! dvix101 divideint  1  2   -> 0
! dvix102 divideint  1  3   -> 0
! dvix103 divideint  1  4   -> 0
! dvix104 divideint  1  5   -> 0
! dvix105 divideint  1  6   -> 0
! dvix106 divideint  1  7   -> 0
! dvix107 divideint  1  8   -> 0
! dvix108 divideint  1  9   -> 0
! dvix109 divideint  1  10  -> 0
! dvix110 divideint  1  1   -> 1
! dvix111 divideint  2  1   -> 2
! dvix112 divideint  3  1   -> 3
! dvix113 divideint  4  1   -> 4
! dvix114 divideint  5  1   -> 5
! dvix115 divideint  6  1   -> 6
! dvix116 divideint  7  1   -> 7
! dvix117 divideint  8  1   -> 8
! dvix118 divideint  9  1   -> 9
! dvix119 divideint  10 1   -> 10
! 
! -- from DiagBigDecimal
! dvix131 divideint  101.3   1     ->  101
! dvix132 divideint  101.0   1     ->  101
! dvix133 divideint  101.3   3     ->  33
! dvix134 divideint  101.0   3     ->  33
! dvix135 divideint  2.4     1     ->  2
! dvix136 divideint  2.400   1     ->  2
! dvix137 divideint  18      18    ->  1
! dvix138 divideint  1120    1000  ->  1
! dvix139 divideint  2.4     2     ->  1
! dvix140 divideint  2.400   2     ->  1
! dvix141 divideint  0.5     2.000 ->  0
! dvix142 divideint  8.005   7     ->  1
! dvix143 divideint  5       2     ->  2
! dvix144 divideint  0       2     ->  0
! dvix145 divideint  0.00    2     ->  0
! 
! -- Others
! dvix150 divideint  12345  4.999  ->  2469
! dvix151 divideint  12345  4.99   ->  2473
! dvix152 divideint  12345  4.9    ->  2519
! dvix153 divideint  12345  5      ->  2469
! dvix154 divideint  12345  5.1    ->  2420
! dvix155 divideint  12345  5.01   ->  2464
! dvix156 divideint  12345  5.001  ->  2468
! dvix157 divideint    101  7.6    ->  13
! 
! -- Various flavours of divideint by 0
! maxexponent: 999999999
! minexponent: -999999999
! dvix201 divideint  0      0   -> NaN Division_undefined
! dvix202 divideint  0.0E5  0   -> NaN Division_undefined
! dvix203 divideint  0.000  0   -> NaN Division_undefined
! dvix204 divideint  0.0001 0   -> Infinity Division_by_zero
! dvix205 divideint  0.01   0   -> Infinity Division_by_zero
! dvix206 divideint  0.1    0   -> Infinity Division_by_zero
! dvix207 divideint  1      0   -> Infinity Division_by_zero
! dvix208 divideint  1      0.0 -> Infinity Division_by_zero
! dvix209 divideint 10      0.0 -> Infinity Division_by_zero
! dvix210 divideint 1E+100  0.0 -> Infinity Division_by_zero
! dvix211 divideint 1E+1000 0   -> Infinity Division_by_zero
! dvix214 divideint  -0.0001 0   -> -Infinity Division_by_zero
! dvix215 divideint  -0.01   0   -> -Infinity Division_by_zero
! dvix216 divideint  -0.1    0   -> -Infinity Division_by_zero
! dvix217 divideint  -1      0   -> -Infinity Division_by_zero
! dvix218 divideint  -1      0.0 -> -Infinity Division_by_zero
! dvix219 divideint -10      0.0 -> -Infinity Division_by_zero
! dvix220 divideint -1E+100  0.0 -> -Infinity Division_by_zero
! dvix221 divideint -1E+1000 0   -> -Infinity Division_by_zero
! 
! -- test some cases that are close to exponent overflow
! maxexponent: 999999999
! minexponent: -999999999
! dvix270 divideint 1 1e999999999    -> 0
! dvix271 divideint 1 0.9e999999999  -> 0
! dvix272 divideint 1 0.99e999999999 -> 0
! dvix273 divideint 1 0.999999999e999999999 -> 0
! dvix274 divideint 9e999999999    1       -> NaN Division_impossible
! dvix275 divideint 9.9e999999999  1       -> NaN Division_impossible
! dvix276 divideint 9.99e999999999 1       -> NaN Division_impossible
! dvix277 divideint 9.99999999e999999999 1 -> NaN Division_impossible
! 
! dvix280 divideint 0.1 9e-999999999       -> NaN Division_impossible
! dvix281 divideint 0.1 99e-999999999      -> NaN Division_impossible
! dvix282 divideint 0.1 999e-999999999     -> NaN Division_impossible
! 
! dvix283 divideint 0.1 9e-999999998       -> NaN Division_impossible
! dvix284 divideint 0.1 99e-999999998      -> NaN Division_impossible
! dvix285 divideint 0.1 999e-999999998     -> NaN Division_impossible
! dvix286 divideint 0.1 999e-999999997     -> NaN Division_impossible
! dvix287 divideint 0.1 9999e-999999997    -> NaN Division_impossible
! dvix288 divideint 0.1 99999e-999999997   -> NaN Division_impossible
! 
! 
! -- overflow and underflow tests [from divide]
! maxexponent: 999999999
! minexponent: -999999999
! dvix330 divideint +1.23456789012345E-0 9E+999999999    -> 0
! dvix331 divideint 9E+999999999 +0.23456789012345E-0 -> NaN Division_impossible
! dvix332 divideint +0.100 9E+999999999    -> 0
! dvix333 divideint 9E-999999999 +9.100    -> 0
! dvix335 divideint -1.23456789012345E-0 9E+999999999    -> -0
! dvix336 divideint 9E+999999999 -0.83456789012345E-0 -> NaN Division_impossible
! dvix337 divideint -0.100 9E+999999999    -> -0
! dvix338 divideint 9E-999999999 -9.100    -> -0
! 
! -- long operand checks
! maxexponent: 999
! minexponent: -999
! precision: 9
! dvix401 divideint 12345678000 100 -> 123456780
! dvix402 divideint 1 12345678000   -> 0
! dvix403 divideint 1234567800  10  -> 123456780
! dvix404 divideint 1 1234567800    -> 0
! dvix405 divideint 1234567890  10  -> 123456789
! dvix406 divideint 1 1234567890    -> 0
! dvix407 divideint 1234567891  10  -> 123456789
! dvix408 divideint 1 1234567891    -> 0
! dvix409 divideint 12345678901 100 -> 123456789
! dvix410 divideint 1 12345678901   -> 0
! dvix411 divideint 1234567896  10  -> 123456789
! dvix412 divideint 1 1234567896    -> 0
! dvix413 divideint 12345678948 100 -> 123456789
! dvix414 divideint 12345678949 100 -> 123456789
! dvix415 divideint 12345678950 100 -> 123456789
! dvix416 divideint 12345678951 100 -> 123456789
! dvix417 divideint 12345678999 100 -> 123456789
! 
! precision: 15
! dvix441 divideint 12345678000 1 -> 12345678000
! dvix442 divideint 1 12345678000 -> 0
! dvix443 divideint 1234567800  1 -> 1234567800
! dvix444 divideint 1 1234567800  -> 0
! dvix445 divideint 1234567890  1 -> 1234567890
! dvix446 divideint 1 1234567890  -> 0
! dvix447 divideint 1234567891  1 -> 1234567891
! dvix448 divideint 1 1234567891  -> 0
! dvix449 divideint 12345678901 1 -> 12345678901
! dvix450 divideint 1 12345678901 -> 0
! dvix451 divideint 1234567896  1 -> 1234567896
! dvix452 divideint 1 1234567896  -> 0
! 
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minexponent: -999
! 
! -- more zeros, etc.
! dvix531 divideint 5.00 1E-3    -> 5000
! dvix532 divideint 00.00 0.000  -> NaN Division_undefined
! dvix533 divideint 00.00 0E-3   -> NaN Division_undefined
! dvix534 divideint  0    -0     -> NaN Division_undefined
! dvix535 divideint -0     0     -> NaN Division_undefined
! dvix536 divideint -0    -0     -> NaN Division_undefined
! 
! dvix541 divideint  0    -1     -> -0
! dvix542 divideint -0    -1     ->  0
! dvix543 divideint  0     1     ->  0
! dvix544 divideint -0     1     -> -0
! dvix545 divideint -1     0     -> -Infinity Division_by_zero
! dvix546 divideint -1    -0     ->  Infinity Division_by_zero
! dvix547 divideint  1     0     ->  Infinity Division_by_zero
! dvix548 divideint  1    -0     -> -Infinity Division_by_zero
! 
! dvix551 divideint  0.0  -1     -> -0
! dvix552 divideint -0.0  -1     ->  0
! dvix553 divideint  0.0   1     ->  0
! dvix554 divideint -0.0   1     -> -0
! dvix555 divideint -1.0   0     -> -Infinity Division_by_zero
! dvix556 divideint -1.0  -0     ->  Infinity Division_by_zero
! dvix557 divideint  1.0   0     ->  Infinity Division_by_zero
! dvix558 divideint  1.0  -0     -> -Infinity Division_by_zero
! 
! dvix561 divideint  0    -1.0   -> -0
! dvix562 divideint -0    -1.0   ->  0
! dvix563 divideint  0     1.0   ->  0
! dvix564 divideint -0     1.0   -> -0
! dvix565 divideint -1     0.0   -> -Infinity Division_by_zero
! dvix566 divideint -1    -0.0   ->  Infinity Division_by_zero
! dvix567 divideint  1     0.0   ->  Infinity Division_by_zero
! dvix568 divideint  1    -0.0   -> -Infinity Division_by_zero
! 
! dvix571 divideint  0.0  -1.0   -> -0
! dvix572 divideint -0.0  -1.0   ->  0
! dvix573 divideint  0.0   1.0   ->  0
! dvix574 divideint -0.0   1.0   -> -0
! dvix575 divideint -1.0   0.0   -> -Infinity Division_by_zero
! dvix576 divideint -1.0  -0.0   ->  Infinity Division_by_zero
! dvix577 divideint  1.0   0.0   ->  Infinity Division_by_zero
! dvix578 divideint  1.0  -0.0   -> -Infinity Division_by_zero
! 
! -- Specials
! dvix580 divideint  Inf  -Inf   ->  NaN Invalid_operation
! dvix581 divideint  Inf  -1000  -> -Infinity
! dvix582 divideint  Inf  -1     -> -Infinity
! dvix583 divideint  Inf  -0     -> -Infinity
! dvix584 divideint  Inf   0     ->  Infinity
! dvix585 divideint  Inf   1     ->  Infinity
! dvix586 divideint  Inf   1000  ->  Infinity
! dvix587 divideint  Inf   Inf   ->  NaN Invalid_operation
! dvix588 divideint -1000  Inf   -> -0
! dvix589 divideint -Inf   Inf   ->  NaN Invalid_operation
! dvix590 divideint -1     Inf   -> -0
! dvix591 divideint -0     Inf   -> -0
! dvix592 divideint  0     Inf   ->  0
! dvix593 divideint  1     Inf   ->  0
! dvix594 divideint  1000  Inf   ->  0
! dvix595 divideint  Inf   Inf   ->  NaN Invalid_operation
! 
! dvix600 divideint -Inf  -Inf   ->  NaN Invalid_operation
! dvix601 divideint -Inf  -1000  ->  Infinity
! dvix602 divideint -Inf  -1     ->  Infinity
! dvix603 divideint -Inf  -0     ->  Infinity
! dvix604 divideint -Inf   0     -> -Infinity
! dvix605 divideint -Inf   1     -> -Infinity
! dvix606 divideint -Inf   1000  -> -Infinity
! dvix607 divideint -Inf   Inf   ->  NaN Invalid_operation
! dvix608 divideint -1000  Inf   -> -0
! dvix609 divideint -Inf  -Inf   ->  NaN Invalid_operation
! dvix610 divideint -1    -Inf   ->  0
! dvix611 divideint -0    -Inf   ->  0
! dvix612 divideint  0    -Inf   -> -0
! dvix613 divideint  1    -Inf   -> -0
! dvix614 divideint  1000 -Inf   -> -0
! dvix615 divideint  Inf  -Inf   ->  NaN Invalid_operation
! 
! dvix621 divideint  NaN -Inf    ->  NaN
! dvix622 divideint  NaN -1000   ->  NaN
! dvix623 divideint  NaN -1      ->  NaN
! dvix624 divideint  NaN -0      ->  NaN
! dvix625 divideint  NaN  0      ->  NaN
! dvix626 divideint  NaN  1      ->  NaN
! dvix627 divideint  NaN  1000   ->  NaN
! dvix628 divideint  NaN  Inf    ->  NaN
! dvix629 divideint  NaN  NaN    ->  NaN
! dvix630 divideint -Inf  NaN    ->  NaN
! dvix631 divideint -1000 NaN    ->  NaN
! dvix632 divideint -1    NaN    ->  NaN
! dvix633 divideint -0    NaN    ->  NaN
! dvix634 divideint  0    NaN    ->  NaN
! dvix635 divideint  1    NaN    ->  NaN
! dvix636 divideint  1000 NaN    ->  NaN
! dvix637 divideint  Inf  NaN    ->  NaN
! 
! dvix641 divideint  sNaN -Inf   ->  NaN  Invalid_operation
! dvix642 divideint  sNaN -1000  ->  NaN  Invalid_operation
! dvix643 divideint  sNaN -1     ->  NaN  Invalid_operation
! dvix644 divideint  sNaN -0     ->  NaN  Invalid_operation
! dvix645 divideint  sNaN  0     ->  NaN  Invalid_operation
! dvix646 divideint  sNaN  1     ->  NaN  Invalid_operation
! dvix647 divideint  sNaN  1000  ->  NaN  Invalid_operation
! dvix648 divideint  sNaN  NaN   ->  NaN  Invalid_operation
! dvix649 divideint  sNaN sNaN   ->  NaN  Invalid_operation
! dvix650 divideint  NaN  sNaN   ->  NaN  Invalid_operation
! dvix651 divideint -Inf  sNaN   ->  NaN  Invalid_operation
! dvix652 divideint -1000 sNaN   ->  NaN  Invalid_operation
! dvix653 divideint -1    sNaN   ->  NaN  Invalid_operation
! dvix654 divideint -0    sNaN   ->  NaN  Invalid_operation
! dvix655 divideint  0    sNaN   ->  NaN  Invalid_operation
! dvix656 divideint  1    sNaN   ->  NaN  Invalid_operation
! dvix657 divideint  1000 sNaN   ->  NaN  Invalid_operation
! dvix658 divideint  Inf  sNaN   ->  NaN  Invalid_operation
! dvix659 divideint  NaN  sNaN   ->  NaN  Invalid_operation
! 
! -- propagating NaNs
! dvix661 divideint  NaN9 -Inf   ->  NaN9
! dvix662 divideint  NaN8  1000  ->  NaN8
! dvix663 divideint  NaN7  Inf   ->  NaN7
! dvix664 divideint -NaN6  NaN5  -> -NaN6
! dvix665 divideint -Inf   NaN4  ->  NaN4
! dvix666 divideint -1000  NaN3  ->  NaN3
! dvix667 divideint  Inf  -NaN2  -> -NaN2
! 
! dvix671 divideint -sNaN99 -Inf    -> -NaN99 Invalid_operation
! dvix672 divideint  sNaN98 -1      ->  NaN98 Invalid_operation
! dvix673 divideint  sNaN97  NaN    ->  NaN97 Invalid_operation
! dvix674 divideint  sNaN96 sNaN94  ->  NaN96 Invalid_operation
! dvix675 divideint  NaN95  sNaN93  ->  NaN93 Invalid_operation
! dvix676 divideint -Inf    sNaN92  ->  NaN92 Invalid_operation
! dvix677 divideint  0      sNaN91  ->  NaN91 Invalid_operation
! dvix678 divideint  Inf   -sNaN90  -> -NaN90 Invalid_operation
! dvix679 divideint  NaN    sNaN89  ->  NaN89 Invalid_operation
! 
! -- some long operand cases again
! precision: 8
! dvix710 divideint  100000001     1  ->  NaN Division_impossible
! dvix711 divideint  100000000.4   1  ->  NaN Division_impossible
! dvix712 divideint  100000000.5   1  ->  NaN Division_impossible
! dvix713 divideint  100000000.9   1  ->  NaN Division_impossible
! dvix714 divideint  100000000.999 1  ->  NaN Division_impossible
! precision: 6
! dvix720 divideint  100000000     1  ->  NaN Division_impossible
! dvix721 divideint  10000000      1  ->  NaN Division_impossible
! dvix722 divideint  1000000       1  ->  NaN Division_impossible
! dvix723 divideint  100000        1  ->  100000
! dvix724 divideint  10000         1  ->  10000
! dvix725 divideint  1000          1  ->  1000
! dvix726 divideint  100           1  ->  100
! dvix727 divideint  10            1  ->  10
! dvix728 divideint  1             1  ->  1
! dvix729 divideint  1            10  ->  0
! 
! precision: 9
! maxexponent: 999999999
! minexponent: -999999999
! dvix732 divideint 1 0.99e999999999 -> 0
! dvix733 divideint 1 0.999999999e999999999 -> 0
! dvix734 divideint 9e999999999    1       -> NaN Division_impossible
! dvix735 divideint 9.9e999999999  1       -> NaN Division_impossible
! dvix736 divideint 9.99e999999999 1       -> NaN Division_impossible
! dvix737 divideint 9.99999999e999999999 1 -> NaN Division_impossible
! 
! dvix740 divideint 0.1 9e-999999999       -> NaN Division_impossible
! dvix741 divideint 0.1 99e-999999999      -> NaN Division_impossible
! dvix742 divideint 0.1 999e-999999999     -> NaN Division_impossible
! 
! dvix743 divideint 0.1 9e-999999998       -> NaN Division_impossible
! dvix744 divideint 0.1 99e-999999998      -> NaN Division_impossible
! dvix745 divideint 0.1 999e-999999998     -> NaN Division_impossible
! dvix746 divideint 0.1 999e-999999997     -> NaN Division_impossible
! dvix747 divideint 0.1 9999e-999999997    -> NaN Division_impossible
! dvix748 divideint 0.1 99999e-999999997   -> NaN Division_impossible
! 
! 
! -- Null tests
! dvix900 divideint  10  # -> NaN Invalid_operation
! dvix901 divideint   # 10 -> NaN Invalid_operation

Index: inexact.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/inexact.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** inexact.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- inexact.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,215 ****
! ------------------------------------------------------------------------
! -- inexact.decTest -- decimal inexact and rounded edge cases          --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.35
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minexponent: -999
! 
! inx001 add 1          1              -> 2
! inx002 add 123456789  0              -> 123456789
! inx003 add 123456789  0.0            -> 123456789 Rounded
! inx004 add 123456789  0.00           -> 123456789 Rounded
! inx005 add 123456789  1              -> 123456790
! inx006 add 123456789  0.1            -> 123456789 Inexact Rounded
! inx007 add 123456789  0.01           -> 123456789 Inexact Rounded
! inx008 add 123456789  0.001          -> 123456789 Inexact Rounded
! inx009 add 123456789  0.000001       -> 123456789 Inexact Rounded
! inx010 add 123456789  0.000000001    -> 123456789 Inexact Rounded
! inx011 add 123456789  0.000000000001 -> 123456789 Inexact Rounded
! 
! inx012 add 123456789  0.9            -> 123456790 Inexact Rounded
! inx013 add 123456789  0.09           -> 123456789 Inexact Rounded
! inx014 add 123456789  0.009          -> 123456789 Inexact Rounded
! inx015 add 123456789  0.000009       -> 123456789 Inexact Rounded
! inx016 add 123456789  0.000000009    -> 123456789 Inexact Rounded
! inx017 add 123456789  0.000000000009 -> 123456789 Inexact Rounded
! 
! inx021 add 1          -1              -> 0
! inx022 add 123456789  -0              -> 123456789
! inx023 add 123456789  -0.0            -> 123456789 Rounded
! inx024 add 123456789  -0.00           -> 123456789 Rounded
! inx025 add 123456789  -1              -> 123456788
! inx026 add 123456789  -0.1            -> 123456789 Inexact Rounded
! inx027 add 123456789  -0.01           -> 123456789 Inexact Rounded
! inx028 add 123456789  -0.001          -> 123456789 Inexact Rounded
! inx029 add 123456789  -0.000001       -> 123456789 Inexact Rounded
! inx030 add 123456789  -0.000000001    -> 123456789 Inexact Rounded
! inx031 add 123456789  -0.000000000001 -> 123456789 Inexact Rounded
! inx032 add 123456789  -0.9            -> 123456788 Inexact Rounded
! inx033 add 123456789  -0.09           -> 123456789 Inexact Rounded
! inx034 add 123456789  -0.009          -> 123456789 Inexact Rounded
! inx035 add 123456789  -0.000009       -> 123456789 Inexact Rounded
! inx036 add 123456789  -0.000000009    -> 123456789 Inexact Rounded
! inx037 add 123456789  -0.000000000009 -> 123456789 Inexact Rounded
! 
! inx042 add  0               123456789 -> 123456789
! inx043 add  0.0             123456789 -> 123456789 Rounded
! inx044 add  0.00            123456789 -> 123456789 Rounded
! inx045 add  1               123456789 -> 123456790
! inx046 add  0.1             123456789 -> 123456789 Inexact Rounded
! inx047 add  0.01            123456789 -> 123456789 Inexact Rounded
! inx048 add  0.001           123456789 -> 123456789 Inexact Rounded
! inx049 add  0.000001        123456789 -> 123456789 Inexact Rounded
! inx050 add  0.000000001     123456789 -> 123456789 Inexact Rounded
! inx051 add  0.000000000001  123456789 -> 123456789 Inexact Rounded
! inx052 add  0.9             123456789 -> 123456790 Inexact Rounded
! inx053 add  0.09            123456789 -> 123456789 Inexact Rounded
! inx054 add  0.009           123456789 -> 123456789 Inexact Rounded
! inx055 add  0.000009        123456789 -> 123456789 Inexact Rounded
! inx056 add  0.000000009     123456789 -> 123456789 Inexact Rounded
! inx057 add  0.000000000009  123456789 -> 123456789 Inexact Rounded
! 
! inx062 add  -0              123456789 -> 123456789
! inx063 add  -0.0            123456789 -> 123456789 Rounded
! inx064 add  -0.00           123456789 -> 123456789 Rounded
! inx065 add  -1              123456789 -> 123456788
! inx066 add  -0.1            123456789 -> 123456789 Inexact Rounded
! inx067 add  -0.01           123456789 -> 123456789 Inexact Rounded
! inx068 add  -0.001          123456789 -> 123456789 Inexact Rounded
! inx069 add  -0.000001       123456789 -> 123456789 Inexact Rounded
! inx070 add  -0.000000001    123456789 -> 123456789 Inexact Rounded
! inx071 add  -0.000000000001 123456789 -> 123456789 Inexact Rounded
! inx072 add  -0.9            123456789 -> 123456788 Inexact Rounded
! inx073 add  -0.09           123456789 -> 123456789 Inexact Rounded
! inx074 add  -0.009          123456789 -> 123456789 Inexact Rounded
! inx075 add  -0.000009       123456789 -> 123456789 Inexact Rounded
! inx076 add  -0.000000009    123456789 -> 123456789 Inexact Rounded
! inx077 add  -0.000000000009 123456789 -> 123456789 Inexact Rounded
! 
! -- some boundaries
! inx081 add    999999999           0     -> 999999999
! inx082 add  0.999999999 0.000000000     -> 0.999999999
! inx083 add    999999999           1     -> 1.00000000E+9 Rounded
! inx084 add  0.999999999 0.000000001     -> 1.00000000    Rounded
! inx085 add    999999999           2     -> 1.00000000E+9 Inexact Rounded
! inx086 add  0.999999999 0.000000002     -> 1.00000000    Inexact Rounded
! inx087 add    999999999           3     -> 1.00000000E+9 Inexact Rounded
! inx089 add  0.999999999 0.000000003     -> 1.00000000    Inexact Rounded
! 
! -- minus, plus, and subtract all assumed to work like add.
! 
! -- multiply
! precision: 8
! inx101 multiply  1000  1000        ->  1000000
! inx102 multiply  9000  9000        -> 81000000
! inx103 multiply  9999  9999        -> 99980001
! inx104 multiply  1000 10000        -> 10000000
! inx105 multiply 10000 10000        -> 1.0000000E+8 Rounded
! inx106 multiply 10001 10000        -> 1.0001000E+8 Rounded
! inx107 multiply 10001 10001        -> 1.0002000E+8 Inexact Rounded
! inx108 multiply 10101 10001        -> 1.0102010E+8 Inexact Rounded
! inx109 multiply 10001 10101        -> 1.0102010E+8 Inexact Rounded
! 
! -- divide
! precision: 4
! inx201 divide  1000  1000        ->  1
! inx202 divide  1000     1        ->  1000
! inx203 divide  1000     2        ->   500
! inx204 divide  1000     3        ->   333.3  Inexact Rounded
! inx205 divide  1000     4        ->   250
! inx206 divide  1000     5        ->   200
! inx207 divide  1000     6        ->   166.7  Inexact Rounded
! inx208 divide  1000     7        ->   142.9  Inexact Rounded
! inx209 divide  1000     8        ->   125
! inx210 divide  1000     9        ->   111.1  Inexact Rounded
! inx211 divide  1000    10        ->   100
! 
! inx220 divide     1     1        ->   1
! inx221 divide     1     2        ->   0.5
! inx222 divide     1     4        ->   0.25
! inx223 divide     1     8        ->   0.125
! inx224 divide     1    16        ->   0.0625
! inx225 divide     1    32        ->   0.03125
! inx226 divide     1    64        ->   0.01563  Inexact Rounded
! inx227 divide     1   128        ->   0.007813 Inexact Rounded
! 
! precision: 5
! inx230 divide     1     1        ->   1
! inx231 divide     1     2        ->   0.5
! inx232 divide     1     4        ->   0.25
! inx233 divide     1     8        ->   0.125
! inx234 divide     1    16        ->   0.0625
! inx235 divide     1    32        ->   0.03125
! inx236 divide     1    64        ->   0.015625
! inx237 divide     1   128        ->   0.0078125
! 
! precision: 3
! inx240 divide     1     1        ->   1
! inx241 divide     1     2        ->   0.5
! inx242 divide     1     4        ->   0.25
! inx243 divide     1     8        ->   0.125
! inx244 divide     1    16        ->   0.0625
! inx245 divide     1    32        ->   0.0313   Inexact Rounded
! inx246 divide     1    64        ->   0.0156   Inexact Rounded
! inx247 divide     1   128        ->   0.00781  Inexact Rounded
! 
! precision: 2
! inx250 divide     1     1        ->   1
! inx251 divide     1     2        ->   0.5
! inx252 divide     1     4        ->   0.25
! inx253 divide     1     8        ->   0.13     Inexact Rounded
! inx254 divide     1    16        ->   0.063    Inexact Rounded
! inx255 divide     1    32        ->   0.031    Inexact Rounded
! inx256 divide     1    64        ->   0.016    Inexact Rounded
! inx257 divide     1   128        ->   0.0078   Inexact Rounded
! 
! precision: 1
! inx260 divide     1     1        ->   1
! inx261 divide     1     2        ->   0.5
! inx262 divide     1     4        ->   0.3      Inexact Rounded
! inx263 divide     1     8        ->   0.1      Inexact Rounded
! inx264 divide     1    16        ->   0.06     Inexact Rounded
! inx265 divide     1    32        ->   0.03     Inexact Rounded
! inx266 divide     1    64        ->   0.02     Inexact Rounded
! inx267 divide     1   128        ->   0.008    Inexact Rounded
! 
! 
! -- power
! precision: 4
! inx301 power    0.5     2        ->   0.25
! inx302 power    0.5     4        ->   0.0625
! inx303 power    0.5     8        ->   0.003906   Inexact Rounded
! inx304 power    0.5    16        ->   0.00001526 Inexact Rounded
! inx305 power    0.5    32        ->   2.328E-10  Inexact Rounded
! 
! -- compare, divideInteger, and remainder are always exact
! 
! -- rescale
! precision: 4
! inx401 rescale 0       0   -> 0
! inx402 rescale 1       0   -> 1
! inx403 rescale 0.1    +2   -> 0E+2 Inexact Rounded
! inx404 rescale 0.1    +1   -> 0E+1 Inexact Rounded
! inx405 rescale 0.1     0   -> 0 Inexact Rounded
! inx406 rescale 0.1    -1   -> 0.1
! inx407 rescale 0.1    -2   -> 0.10
! 
! -- long operands cause rounding too
! precision: 9
! inx801 plus  123456789  -> 123456789
! inx802 plus  1234567890 -> 1.23456789E+9 Rounded
! inx803 plus  1234567891 -> 1.23456789E+9 Inexact Rounded
! inx804 plus  1234567892 -> 1.23456789E+9 Inexact Rounded
! inx805 plus  1234567899 -> 1.23456790E+9 Inexact Rounded
! inx806 plus  1234567900 -> 1.23456790E+9 Rounded
! 
--- 1,215 ----
! ------------------------------------------------------------------------
! -- inexact.decTest -- decimal inexact and rounded edge cases          --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.38
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minexponent: -999
! 
! inx001 add 1          1              -> 2
! inx002 add 123456789  0              -> 123456789
! inx003 add 123456789  0.0            -> 123456789 Rounded
! inx004 add 123456789  0.00           -> 123456789 Rounded
! inx005 add 123456789  1              -> 123456790
! inx006 add 123456789  0.1            -> 123456789 Inexact Rounded
! inx007 add 123456789  0.01           -> 123456789 Inexact Rounded
! inx008 add 123456789  0.001          -> 123456789 Inexact Rounded
! inx009 add 123456789  0.000001       -> 123456789 Inexact Rounded
! inx010 add 123456789  0.000000001    -> 123456789 Inexact Rounded
! inx011 add 123456789  0.000000000001 -> 123456789 Inexact Rounded
! 
! inx012 add 123456789  0.9            -> 123456790 Inexact Rounded
! inx013 add 123456789  0.09           -> 123456789 Inexact Rounded
! inx014 add 123456789  0.009          -> 123456789 Inexact Rounded
! inx015 add 123456789  0.000009       -> 123456789 Inexact Rounded
! inx016 add 123456789  0.000000009    -> 123456789 Inexact Rounded
! inx017 add 123456789  0.000000000009 -> 123456789 Inexact Rounded
! 
! inx021 add 1          -1              -> 0
! inx022 add 123456789  -0              -> 123456789
! inx023 add 123456789  -0.0            -> 123456789 Rounded
! inx024 add 123456789  -0.00           -> 123456789 Rounded
! inx025 add 123456789  -1              -> 123456788
! inx026 add 123456789  -0.1            -> 123456789 Inexact Rounded
! inx027 add 123456789  -0.01           -> 123456789 Inexact Rounded
! inx028 add 123456789  -0.001          -> 123456789 Inexact Rounded
! inx029 add 123456789  -0.000001       -> 123456789 Inexact Rounded
! inx030 add 123456789  -0.000000001    -> 123456789 Inexact Rounded
! inx031 add 123456789  -0.000000000001 -> 123456789 Inexact Rounded
! inx032 add 123456789  -0.9            -> 123456788 Inexact Rounded
! inx033 add 123456789  -0.09           -> 123456789 Inexact Rounded
! inx034 add 123456789  -0.009          -> 123456789 Inexact Rounded
! inx035 add 123456789  -0.000009       -> 123456789 Inexact Rounded
! inx036 add 123456789  -0.000000009    -> 123456789 Inexact Rounded
! inx037 add 123456789  -0.000000000009 -> 123456789 Inexact Rounded
! 
! inx042 add  0               123456789 -> 123456789
! inx043 add  0.0             123456789 -> 123456789 Rounded
! inx044 add  0.00            123456789 -> 123456789 Rounded
! inx045 add  1               123456789 -> 123456790
! inx046 add  0.1             123456789 -> 123456789 Inexact Rounded
! inx047 add  0.01            123456789 -> 123456789 Inexact Rounded
! inx048 add  0.001           123456789 -> 123456789 Inexact Rounded
! inx049 add  0.000001        123456789 -> 123456789 Inexact Rounded
! inx050 add  0.000000001     123456789 -> 123456789 Inexact Rounded
! inx051 add  0.000000000001  123456789 -> 123456789 Inexact Rounded
! inx052 add  0.9             123456789 -> 123456790 Inexact Rounded
! inx053 add  0.09            123456789 -> 123456789 Inexact Rounded
! inx054 add  0.009           123456789 -> 123456789 Inexact Rounded
! inx055 add  0.000009        123456789 -> 123456789 Inexact Rounded
! inx056 add  0.000000009     123456789 -> 123456789 Inexact Rounded
! inx057 add  0.000000000009  123456789 -> 123456789 Inexact Rounded
! 
! inx062 add  -0              123456789 -> 123456789
! inx063 add  -0.0            123456789 -> 123456789 Rounded
! inx064 add  -0.00           123456789 -> 123456789 Rounded
! inx065 add  -1              123456789 -> 123456788
! inx066 add  -0.1            123456789 -> 123456789 Inexact Rounded
! inx067 add  -0.01           123456789 -> 123456789 Inexact Rounded
! inx068 add  -0.001          123456789 -> 123456789 Inexact Rounded
! inx069 add  -0.000001       123456789 -> 123456789 Inexact Rounded
! inx070 add  -0.000000001    123456789 -> 123456789 Inexact Rounded
! inx071 add  -0.000000000001 123456789 -> 123456789 Inexact Rounded
! inx072 add  -0.9            123456789 -> 123456788 Inexact Rounded
! inx073 add  -0.09           123456789 -> 123456789 Inexact Rounded
! inx074 add  -0.009          123456789 -> 123456789 Inexact Rounded
! inx075 add  -0.000009       123456789 -> 123456789 Inexact Rounded
! inx076 add  -0.000000009    123456789 -> 123456789 Inexact Rounded
! inx077 add  -0.000000000009 123456789 -> 123456789 Inexact Rounded
! 
! -- some boundaries
! inx081 add    999999999           0     -> 999999999
! inx082 add  0.999999999 0.000000000     -> 0.999999999
! inx083 add    999999999           1     -> 1.00000000E+9 Rounded
! inx084 add  0.999999999 0.000000001     -> 1.00000000    Rounded
! inx085 add    999999999           2     -> 1.00000000E+9 Inexact Rounded
! inx086 add  0.999999999 0.000000002     -> 1.00000000    Inexact Rounded
! inx087 add    999999999           3     -> 1.00000000E+9 Inexact Rounded
! inx089 add  0.999999999 0.000000003     -> 1.00000000    Inexact Rounded
! 
! -- minus, plus, and subtract all assumed to work like add.
! 
! -- multiply
! precision: 8
! inx101 multiply  1000  1000        ->  1000000
! inx102 multiply  9000  9000        -> 81000000
! inx103 multiply  9999  9999        -> 99980001
! inx104 multiply  1000 10000        -> 10000000
! inx105 multiply 10000 10000        -> 1.0000000E+8 Rounded
! inx106 multiply 10001 10000        -> 1.0001000E+8 Rounded
! inx107 multiply 10001 10001        -> 1.0002000E+8 Inexact Rounded
! inx108 multiply 10101 10001        -> 1.0102010E+8 Inexact Rounded
! inx109 multiply 10001 10101        -> 1.0102010E+8 Inexact Rounded
! 
! -- divide
! precision: 4
! inx201 divide  1000  1000        ->  1
! inx202 divide  1000     1        ->  1000
! inx203 divide  1000     2        ->   500
! inx204 divide  1000     3        ->   333.3  Inexact Rounded
! inx205 divide  1000     4        ->   250
! inx206 divide  1000     5        ->   200
! inx207 divide  1000     6        ->   166.7  Inexact Rounded
! inx208 divide  1000     7        ->   142.9  Inexact Rounded
! inx209 divide  1000     8        ->   125
! inx210 divide  1000     9        ->   111.1  Inexact Rounded
! inx211 divide  1000    10        ->   100
! 
! inx220 divide     1     1        ->   1
! inx221 divide     1     2        ->   0.5
! inx222 divide     1     4        ->   0.25
! inx223 divide     1     8        ->   0.125
! inx224 divide     1    16        ->   0.0625
! inx225 divide     1    32        ->   0.03125
! inx226 divide     1    64        ->   0.01563  Inexact Rounded
! inx227 divide     1   128        ->   0.007813 Inexact Rounded
! 
! precision: 5
! inx230 divide     1     1        ->   1
! inx231 divide     1     2        ->   0.5
! inx232 divide     1     4        ->   0.25
! inx233 divide     1     8        ->   0.125
! inx234 divide     1    16        ->   0.0625
! inx235 divide     1    32        ->   0.03125
! inx236 divide     1    64        ->   0.015625
! inx237 divide     1   128        ->   0.0078125
! 
! precision: 3
! inx240 divide     1     1        ->   1
! inx241 divide     1     2        ->   0.5
! inx242 divide     1     4        ->   0.25
! inx243 divide     1     8        ->   0.125
! inx244 divide     1    16        ->   0.0625
! inx245 divide     1    32        ->   0.0313   Inexact Rounded
! inx246 divide     1    64        ->   0.0156   Inexact Rounded
! inx247 divide     1   128        ->   0.00781  Inexact Rounded
! 
! precision: 2
! inx250 divide     1     1        ->   1
! inx251 divide     1     2        ->   0.5
! inx252 divide     1     4        ->   0.25
! inx253 divide     1     8        ->   0.13     Inexact Rounded
! inx254 divide     1    16        ->   0.063    Inexact Rounded
! inx255 divide     1    32        ->   0.031    Inexact Rounded
! inx256 divide     1    64        ->   0.016    Inexact Rounded
! inx257 divide     1   128        ->   0.0078   Inexact Rounded
! 
! precision: 1
! inx260 divide     1     1        ->   1
! inx261 divide     1     2        ->   0.5
! inx262 divide     1     4        ->   0.3      Inexact Rounded
! inx263 divide     1     8        ->   0.1      Inexact Rounded
! inx264 divide     1    16        ->   0.06     Inexact Rounded
! inx265 divide     1    32        ->   0.03     Inexact Rounded
! inx266 divide     1    64        ->   0.02     Inexact Rounded
! inx267 divide     1   128        ->   0.008    Inexact Rounded
! 
! 
! -- power
! precision: 4
! inx301 power    0.5     2        ->   0.25
! inx302 power    0.5     4        ->   0.0625
! inx303 power    0.5     8        ->   0.003906   Inexact Rounded
! inx304 power    0.5    16        ->   0.00001526 Inexact Rounded
! inx305 power    0.5    32        ->   2.328E-10  Inexact Rounded
! 
! -- compare, divideInteger, and remainder are always exact
! 
! -- rescale
! precision: 4
! inx401 rescale 0       0   -> 0
! inx402 rescale 1       0   -> 1
! inx403 rescale 0.1    +2   -> 0E+2 Inexact Rounded
! inx404 rescale 0.1    +1   -> 0E+1 Inexact Rounded
! inx405 rescale 0.1     0   -> 0 Inexact Rounded
! inx406 rescale 0.1    -1   -> 0.1
! inx407 rescale 0.1    -2   -> 0.10
! 
! -- long operands cause rounding too
! precision: 9
! inx801 plus  123456789  -> 123456789
! inx802 plus  1234567890 -> 1.23456789E+9 Rounded
! inx803 plus  1234567891 -> 1.23456789E+9 Inexact Rounded
! inx804 plus  1234567892 -> 1.23456789E+9 Inexact Rounded
! inx805 plus  1234567899 -> 1.23456790E+9 Inexact Rounded
! inx806 plus  1234567900 -> 1.23456790E+9 Rounded
! 

Index: max.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/max.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** max.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- max.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,300 ****
! ------------------------------------------------------------------------
! -- max.decTest -- decimal maximum                                     --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.35
! 
! -- we assume that base comparison is tested in compare.decTest, so
! -- these mainly cover special cases and rounding
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minexponent: -999
! 
! -- sanity checks
! maxx001 max  -2  -2  -> -2
! maxx002 max  -2  -1  -> -1
! maxx003 max  -2   0  ->  0
! maxx004 max  -2   1  ->  1
! maxx005 max  -2   2  ->  2
! maxx006 max  -1  -2  -> -1
! maxx007 max  -1  -1  -> -1
! maxx008 max  -1   0  ->  0
! maxx009 max  -1   1  ->  1
! maxx010 max  -1   2  ->  2
! maxx011 max   0  -2  ->  0
! maxx012 max   0  -1  ->  0
! maxx013 max   0   0  ->  0
! maxx014 max   0   1  ->  1
! maxx015 max   0   2  ->  2
! maxx016 max   1  -2  ->  1
! maxx017 max   1  -1  ->  1
! maxx018 max   1   0  ->  1
! maxx019 max   1   1  ->  1
! maxx020 max   1   2  ->  2
! maxx021 max   2  -2  ->  2
! maxx022 max   2  -1  ->  2
! maxx023 max   2   0  ->  2
! maxx025 max   2   1  ->  2
! maxx026 max   2   2  ->  2
! 
! -- extended zeros
! maxx030 max   0     0   ->  0
! maxx031 max   0    -0   ->  0
! maxx032 max   0    -0.0 ->  0
! maxx033 max   0     0.0 ->  0
! maxx034 max  -0     0   -> -0    -- note: -0 = 0
! maxx035 max  -0    -0   -> -0
! maxx036 max  -0    -0.0 -> -0
! maxx037 max  -0     0.0 -> -0
! maxx038 max   0.0   0   ->  0.0
! maxx039 max   0.0  -0   ->  0.0
! maxx040 max   0.0  -0.0 ->  0.0
! maxx041 max   0.0   0.0 ->  0.0
! maxx042 max  -0.0   0   -> -0.0
! maxx043 max  -0.0  -0   -> -0.0
! maxx044 max  -0.0  -0.0 -> -0.0
! maxx045 max  -0.0   0.0 -> -0.0
! 
! maxx046 max  -0E1   0E2 -> -0E+1
! maxx047 max   0E2   0E1 ->  0E+2
! maxx048 max   0E1   0E2 ->  0E+1
! maxx049 max  -0E3  -0E2 -> -0E+3
! 
! 
! -- Specials
! precision: 9
! maxx090 max  Inf  -Inf   ->  Infinity
! maxx091 max  Inf  -1000  ->  Infinity
! maxx092 max  Inf  -1     ->  Infinity
! maxx093 max  Inf  -0     ->  Infinity
! maxx094 max  Inf   0     ->  Infinity
! maxx095 max  Inf   1     ->  Infinity
! maxx096 max  Inf   1000  ->  Infinity
! maxx097 max  Inf   Inf   ->  Infinity
! maxx098 max -1000  Inf   ->  Infinity
! maxx099 max -Inf   Inf   ->  Infinity
! maxx100 max -1     Inf   ->  Infinity
! maxx101 max -0     Inf   ->  Infinity
! maxx102 max  0     Inf   ->  Infinity
! maxx103 max  1     Inf   ->  Infinity
! maxx104 max  1000  Inf   ->  Infinity
! maxx105 max  Inf   Inf   ->  Infinity
! 
! maxx120 max -Inf  -Inf   -> -Infinity
! maxx121 max -Inf  -1000  -> -1000
! maxx122 max -Inf  -1     -> -1
! maxx123 max -Inf  -0     -> -0
! maxx124 max -Inf   0     ->  0
! maxx125 max -Inf   1     ->  1
! maxx126 max -Inf   1000  ->  1000
! maxx127 max -Inf   Inf   ->  Infinity
! maxx128 max -Inf  -Inf   ->  -Infinity
! maxx129 max -1000 -Inf   ->  -1000
! maxx130 max -1    -Inf   ->  -1
! maxx131 max -0    -Inf   ->  -0
! maxx132 max  0    -Inf   ->  0
! maxx133 max  1    -Inf   ->  1
! maxx134 max  1000 -Inf   ->  1000
! maxx135 max  Inf  -Inf   ->  Infinity
! 
! maxx141 max  NaN -Inf    ->  NaN
! maxx142 max  NaN -1000   ->  NaN
! maxx143 max  NaN -1      ->  NaN
! maxx144 max  NaN -0      ->  NaN
! maxx145 max  NaN  0      ->  NaN
! maxx146 max  NaN  1      ->  NaN
! maxx147 max  NaN  1000   ->  NaN
! maxx148 max  NaN  Inf    ->  NaN
! maxx149 max  NaN  NaN    ->  NaN
! maxx150 max -Inf  NaN    ->  NaN
! maxx151 max -1000 NaN    ->  NaN
! maxx152 max -1    NaN    ->  NaN
! maxx153 max -0    NaN    ->  NaN
! maxx154 max  0    NaN    ->  NaN
! maxx155 max  1    NaN    ->  NaN
! maxx156 max  1000 NaN    ->  NaN
! maxx157 max  Inf  NaN    ->  NaN
! 
! maxx161 max  sNaN -Inf   ->  NaN  Invalid_operation
! maxx162 max  sNaN -1000  ->  NaN  Invalid_operation
! maxx163 max  sNaN -1     ->  NaN  Invalid_operation
! maxx164 max  sNaN -0     ->  NaN  Invalid_operation
! maxx165 max  sNaN  0     ->  NaN  Invalid_operation
! maxx166 max  sNaN  1     ->  NaN  Invalid_operation
! maxx167 max  sNaN  1000  ->  NaN  Invalid_operation
! maxx168 max  sNaN  NaN   ->  NaN  Invalid_operation
! maxx169 max  sNaN sNaN   ->  NaN  Invalid_operation
! maxx170 max  NaN  sNaN   ->  NaN  Invalid_operation
! maxx171 max -Inf  sNaN   ->  NaN  Invalid_operation
! maxx172 max -1000 sNaN   ->  NaN  Invalid_operation
! maxx173 max -1    sNaN   ->  NaN  Invalid_operation
! maxx174 max -0    sNaN   ->  NaN  Invalid_operation
! maxx175 max  0    sNaN   ->  NaN  Invalid_operation
! maxx176 max  1    sNaN   ->  NaN  Invalid_operation
! maxx177 max  1000 sNaN   ->  NaN  Invalid_operation
! maxx178 max  Inf  sNaN   ->  NaN  Invalid_operation
! maxx179 max  NaN  sNaN   ->  NaN  Invalid_operation
! 
! -- propagating NaNs
! maxx181 max  NaN9 -Inf   ->  NaN9
! maxx182 max  NaN8    9   ->  NaN8
! maxx183 max -NaN7  Inf   -> -NaN7
! maxx184 max  NaN6  NaN5  ->  NaN6
! maxx185 max -Inf   NaN4  ->  NaN4
! maxx186 max -9    -NaN3  -> -NaN3
! maxx187 max  Inf   NaN2  ->  NaN2
! 
! maxx191 max  sNaN99 -Inf    ->  NaN99 Invalid_operation
! maxx192 max  sNaN98 -1      ->  NaN98 Invalid_operation
! maxx193 max -sNaN97  NaN    -> -NaN97 Invalid_operation
! maxx194 max  sNaN96 sNaN94  ->  NaN96 Invalid_operation
! maxx195 max  NaN95  sNaN93  ->  NaN93 Invalid_operation
! maxx196 max -Inf    sNaN92  ->  NaN92 Invalid_operation
! maxx197 max  0      sNaN91  ->  NaN91 Invalid_operation
! maxx198 max  Inf   -sNaN90  -> -NaN90 Invalid_operation
! maxx199 max  NaN    sNaN89  ->  NaN89 Invalid_operation
! 
! -- rounding checks
! maxexponent: 999
! minexponent: -999
! precision: 9
! maxx201 max 12345678000 1  -> 1.23456780E+10 Rounded
! maxx202 max 1 12345678000  -> 1.23456780E+10 Rounded
! maxx203 max 1234567800  1  -> 1.23456780E+9 Rounded
! maxx204 max 1 1234567800   -> 1.23456780E+9 Rounded
! maxx205 max 1234567890  1  -> 1.23456789E+9 Rounded
! maxx206 max 1 1234567890   -> 1.23456789E+9 Rounded
! maxx207 max 1234567891  1  -> 1.23456789E+9 Inexact Rounded
! maxx208 max 1 1234567891   -> 1.23456789E+9 Inexact Rounded
! maxx209 max 12345678901 1  -> 1.23456789E+10 Inexact Rounded
! maxx210 max 1 12345678901  -> 1.23456789E+10 Inexact Rounded
! maxx211 max 1234567896  1  -> 1.23456790E+9 Inexact Rounded
! maxx212 max 1 1234567896   -> 1.23456790E+9 Inexact Rounded
! maxx213 max -1234567891  1 -> 1
! maxx214 max 1 -1234567891  -> 1
! maxx215 max -12345678901 1 -> 1
! maxx216 max 1 -12345678901 -> 1
! maxx217 max -1234567896  1 -> 1
! maxx218 max 1 -1234567896  -> 1
! 
! precision: 15
! maxx221 max 12345678000 1  -> 12345678000
! maxx222 max 1 12345678000  -> 12345678000
! maxx223 max 1234567800  1  -> 1234567800
! maxx224 max 1 1234567800   -> 1234567800
! maxx225 max 1234567890  1  -> 1234567890
! maxx226 max 1 1234567890   -> 1234567890
! maxx227 max 1234567891  1  -> 1234567891
! maxx228 max 1 1234567891   -> 1234567891
! maxx229 max 12345678901 1  -> 12345678901
! maxx230 max 1 12345678901  -> 12345678901
! maxx231 max 1234567896  1  -> 1234567896
! maxx232 max 1 1234567896   -> 1234567896
! maxx233 max -1234567891  1 -> 1
! maxx234 max 1 -1234567891  -> 1
! maxx235 max -12345678901 1 -> 1
! maxx236 max 1 -12345678901 -> 1
! maxx237 max -1234567896  1 -> 1
! maxx238 max 1 -1234567896  -> 1
! 
! -- from examples
! maxx280 max '3'   '2'  ->  '3'
! maxx281 max '-10' '3'  ->  '3'
! maxx282 max '1.0' '1'  ->  '1.0'
! maxx283 max '1' '1.0'  ->  '1'
! 
! -- overflow and underflow tests ...
! maxExponent: 999999999
! minexponent: -999999999
! maxx330 max +1.23456789012345E-0 9E+999999999 ->  9E+999999999
! maxx331 max 9E+999999999 +1.23456789012345E-0 ->  9E+999999999
! maxx332 max +0.100 9E-999999999               ->  0.100
! maxx333 max 9E-999999999 +0.100               ->  0.100
! maxx335 max -1.23456789012345E-0 9E+999999999 ->  9E+999999999
! maxx336 max 9E+999999999 -1.23456789012345E-0 ->  9E+999999999
! maxx337 max -0.100 9E-999999999               ->  9E-999999999
! maxx338 max 9E-999999999 -0.100               ->  9E-999999999
! 
! maxx339 max 1e-599999999 1e-400000001   ->  1E-400000001
! maxx340 max 1e-599999999 1e-400000000   ->  1E-400000000
! maxx341 max 1e-600000000 1e-400000000   ->  1E-400000000
! maxx342 max 9e-999999998 0.01           ->  0.01
! maxx343 max 9e-999999998 0.1            ->  0.1
! maxx344 max 0.01 9e-999999998           ->  0.01
! maxx345 max 1e599999999 1e400000001     ->  1E+599999999
! maxx346 max 1e599999999 1e400000000     ->  1E+599999999
! maxx347 max 1e600000000 1e400000000     ->  1E+600000000
! maxx348 max 9e999999998 100             ->  9E+999999998
! maxx349 max 9e999999998 10              ->  9E+999999998
! maxx350 max 100  9e999999998            ->  9E+999999998
! -- signs
! maxx351 max  1e+777777777  1e+411111111 ->  1E+777777777
! maxx352 max  1e+777777777 -1e+411111111 ->  1E+777777777
! maxx353 max -1e+777777777  1e+411111111 ->  1E+411111111
! maxx354 max -1e+777777777 -1e+411111111 -> -1E+411111111
! maxx355 max  1e-777777777  1e-411111111 ->  1E-411111111
! maxx356 max  1e-777777777 -1e-411111111 ->  1E-777777777
! maxx357 max -1e-777777777  1e-411111111 ->  1E-411111111
! maxx358 max -1e-777777777 -1e-411111111 -> -1E-777777777
! 
! 
! -- overflow tests
! maxexponent: 999999999
! minexponent: -999999999
! precision: 3
! maxx400 max 9.999E+999999999  0 ->  Infinity Inexact Overflow Rounded
! maxx401 max -9.999E+999999999 0 ->  0
! 
! -- subnormals and underflow
! precision: 3
! maxexponent: 999
! minexponent: -999
! maxx410 max  1.00E-999       0  ->   1.00E-999
! maxx411 max  0.1E-999        0  ->   1E-1000   Subnormal
! maxx412 max  0.10E-999       0  ->   1.0E-1000 Subnormal
! maxx413 max  0.100E-999      0  ->   1.0E-1000 Subnormal Rounded
! maxx414 max  0.01E-999       0  ->   1E-1001   Subnormal
! -- next is rounded to Emin
! maxx415 max  0.999E-999      0  ->   1.00E-999 Inexact Rounded Subnormal Underflow
! maxx416 max  0.099E-999      0  ->   1.0E-1000 Inexact Rounded Subnormal Underflow
! maxx417 max  0.009E-999      0  ->   1E-1001   Inexact Rounded Subnormal Underflow
! maxx418 max  0.001E-999      0  ->   0E-1001   Inexact Rounded Subnormal Underflow
! maxx419 max  0.0009E-999     0  ->   0E-1001   Inexact Rounded Subnormal Underflow
! maxx420 max  0.0001E-999     0  ->   0E-1001   Inexact Rounded Subnormal Underflow
! 
! maxx430 max -1.00E-999       0  ->   0
! maxx431 max -0.1E-999        0  ->   0
! maxx432 max -0.10E-999       0  ->   0
! maxx433 max -0.100E-999      0  ->   0
! maxx434 max -0.01E-999       0  ->   0
! maxx435 max -0.999E-999      0  ->   0
! maxx436 max -0.099E-999      0  ->   0
! maxx437 max -0.009E-999      0  ->   0
! maxx438 max -0.001E-999      0  ->   0
! maxx439 max -0.0009E-999     0  ->   0
! maxx440 max -0.0001E-999     0  ->   0
! 
! -- Null tests
! maxx900 max 10  #  -> NaN Invalid_operation
! maxx901 max  # 10  -> NaN Invalid_operation
! 
! 
! 
--- 1,300 ----
! ------------------------------------------------------------------------
! -- max.decTest -- decimal maximum                                     --
! -- Copyright (c) IBM Corporation, 1981, 2004.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.38
! 
! -- we assume that base comparison is tested in compare.decTest, so
! -- these mainly cover special cases and rounding
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 384
! minexponent: -383
! 
! -- sanity checks
! maxx001 max  -2  -2  -> -2
! maxx002 max  -2  -1  -> -1
! maxx003 max  -2   0  ->  0
! maxx004 max  -2   1  ->  1
! maxx005 max  -2   2  ->  2
! maxx006 max  -1  -2  -> -1
! maxx007 max  -1  -1  -> -1
! maxx008 max  -1   0  ->  0
! maxx009 max  -1   1  ->  1
! maxx010 max  -1   2  ->  2
! maxx011 max   0  -2  ->  0
! maxx012 max   0  -1  ->  0
! maxx013 max   0   0  ->  0
! maxx014 max   0   1  ->  1
! maxx015 max   0   2  ->  2
! maxx016 max   1  -2  ->  1
! maxx017 max   1  -1  ->  1
! maxx018 max   1   0  ->  1
! maxx019 max   1   1  ->  1
! maxx020 max   1   2  ->  2
! maxx021 max   2  -2  ->  2
! maxx022 max   2  -1  ->  2
! maxx023 max   2   0  ->  2
! maxx025 max   2   1  ->  2
! maxx026 max   2   2  ->  2
! 
! -- extended zeros
! maxx030 max   0     0   ->  0
! maxx031 max   0    -0   ->  0
! maxx032 max   0    -0.0 ->  0
! maxx033 max   0     0.0 ->  0
! maxx034 max  -0     0   -> -0    -- note: -0 = 0
! maxx035 max  -0    -0   -> -0
! maxx036 max  -0    -0.0 -> -0
! maxx037 max  -0     0.0 -> -0
! maxx038 max   0.0   0   ->  0.0
! maxx039 max   0.0  -0   ->  0.0
! maxx040 max   0.0  -0.0 ->  0.0
! maxx041 max   0.0   0.0 ->  0.0
! maxx042 max  -0.0   0   -> -0.0
! maxx043 max  -0.0  -0   -> -0.0
! maxx044 max  -0.0  -0.0 -> -0.0
! maxx045 max  -0.0   0.0 -> -0.0
! 
! maxx046 max  -0E1   0E2 -> -0E+1
! maxx047 max   0E2   0E1 ->  0E+2
! maxx048 max   0E1   0E2 ->  0E+1
! maxx049 max  -0E3  -0E2 -> -0E+3
! 
! 
! -- Specials
! precision: 9
! maxx090 max  Inf  -Inf   ->  Infinity
! maxx091 max  Inf  -1000  ->  Infinity
! maxx092 max  Inf  -1     ->  Infinity
! maxx093 max  Inf  -0     ->  Infinity
! maxx094 max  Inf   0     ->  Infinity
! maxx095 max  Inf   1     ->  Infinity
! maxx096 max  Inf   1000  ->  Infinity
! maxx097 max  Inf   Inf   ->  Infinity
! maxx098 max -1000  Inf   ->  Infinity
! maxx099 max -Inf   Inf   ->  Infinity
! maxx100 max -1     Inf   ->  Infinity
! maxx101 max -0     Inf   ->  Infinity
! maxx102 max  0     Inf   ->  Infinity
! maxx103 max  1     Inf   ->  Infinity
! maxx104 max  1000  Inf   ->  Infinity
! maxx105 max  Inf   Inf   ->  Infinity
! 
! maxx120 max -Inf  -Inf   -> -Infinity
! maxx121 max -Inf  -1000  -> -1000
! maxx122 max -Inf  -1     -> -1
! maxx123 max -Inf  -0     -> -0
! maxx124 max -Inf   0     ->  0
! maxx125 max -Inf   1     ->  1
! maxx126 max -Inf   1000  ->  1000
! maxx127 max -Inf   Inf   ->  Infinity
! maxx128 max -Inf  -Inf   ->  -Infinity
! maxx129 max -1000 -Inf   ->  -1000
! maxx130 max -1    -Inf   ->  -1
! maxx131 max -0    -Inf   ->  -0
! maxx132 max  0    -Inf   ->  0
! maxx133 max  1    -Inf   ->  1
! maxx134 max  1000 -Inf   ->  1000
! maxx135 max  Inf  -Inf   ->  Infinity
! 
! maxx141 max  NaN -Inf    ->  NaN
! maxx142 max  NaN -1000   ->  NaN
! maxx143 max  NaN -1      ->  NaN
! maxx144 max  NaN -0      ->  NaN
! maxx145 max  NaN  0      ->  NaN
! maxx146 max  NaN  1      ->  NaN
! maxx147 max  NaN  1000   ->  NaN
! maxx148 max  NaN  Inf    ->  NaN
! maxx149 max  NaN  NaN    ->  NaN
! maxx150 max -Inf  NaN    ->  NaN
! maxx151 max -1000 NaN    ->  NaN
! maxx152 max -1    NaN    ->  NaN
! maxx153 max -0    NaN    ->  NaN
! maxx154 max  0    NaN    ->  NaN
! maxx155 max  1    NaN    ->  NaN
! maxx156 max  1000 NaN    ->  NaN
! maxx157 max  Inf  NaN    ->  NaN
! 
! maxx161 max  sNaN -Inf   ->  NaN  Invalid_operation
! maxx162 max  sNaN -1000  ->  NaN  Invalid_operation
! maxx163 max  sNaN -1     ->  NaN  Invalid_operation
! maxx164 max  sNaN -0     ->  NaN  Invalid_operation
! maxx165 max  sNaN  0     ->  NaN  Invalid_operation
! maxx166 max  sNaN  1     ->  NaN  Invalid_operation
! maxx167 max  sNaN  1000  ->  NaN  Invalid_operation
! maxx168 max  sNaN  NaN   ->  NaN  Invalid_operation
! maxx169 max  sNaN sNaN   ->  NaN  Invalid_operation
! maxx170 max  NaN  sNaN   ->  NaN  Invalid_operation
! maxx171 max -Inf  sNaN   ->  NaN  Invalid_operation
! maxx172 max -1000 sNaN   ->  NaN  Invalid_operation
! maxx173 max -1    sNaN   ->  NaN  Invalid_operation
! maxx174 max -0    sNaN   ->  NaN  Invalid_operation
! maxx175 max  0    sNaN   ->  NaN  Invalid_operation
! maxx176 max  1    sNaN   ->  NaN  Invalid_operation
! maxx177 max  1000 sNaN   ->  NaN  Invalid_operation
! maxx178 max  Inf  sNaN   ->  NaN  Invalid_operation
! maxx179 max  NaN  sNaN   ->  NaN  Invalid_operation
! 
! -- propagating NaNs
! maxx181 max  NaN9 -Inf   ->  NaN9
! maxx182 max  NaN8    9   ->  NaN8
! maxx183 max -NaN7  Inf   -> -NaN7
! maxx184 max  NaN6  NaN5  ->  NaN6
! maxx185 max -Inf   NaN4  ->  NaN4
! maxx186 max -9    -NaN3  -> -NaN3
! maxx187 max  Inf   NaN2  ->  NaN2
! 
! maxx191 max  sNaN99 -Inf    ->  NaN99 Invalid_operation
! maxx192 max  sNaN98 -1      ->  NaN98 Invalid_operation
! maxx193 max -sNaN97  NaN    -> -NaN97 Invalid_operation
! maxx194 max  sNaN96 sNaN94  ->  NaN96 Invalid_operation
! maxx195 max  NaN95  sNaN93  ->  NaN93 Invalid_operation
! maxx196 max -Inf    sNaN92  ->  NaN92 Invalid_operation
! maxx197 max  0      sNaN91  ->  NaN91 Invalid_operation
! maxx198 max  Inf   -sNaN90  -> -NaN90 Invalid_operation
! maxx199 max  NaN    sNaN89  ->  NaN89 Invalid_operation
! 
! -- rounding checks
! maxexponent: 999
! minexponent: -999
! precision: 9
! maxx201 max 12345678000 1  -> 1.23456780E+10 Rounded
! maxx202 max 1 12345678000  -> 1.23456780E+10 Rounded
! maxx203 max 1234567800  1  -> 1.23456780E+9 Rounded
! maxx204 max 1 1234567800   -> 1.23456780E+9 Rounded
! maxx205 max 1234567890  1  -> 1.23456789E+9 Rounded
! maxx206 max 1 1234567890   -> 1.23456789E+9 Rounded
! maxx207 max 1234567891  1  -> 1.23456789E+9 Inexact Rounded
! maxx208 max 1 1234567891   -> 1.23456789E+9 Inexact Rounded
! maxx209 max 12345678901 1  -> 1.23456789E+10 Inexact Rounded
! maxx210 max 1 12345678901  -> 1.23456789E+10 Inexact Rounded
! maxx211 max 1234567896  1  -> 1.23456790E+9 Inexact Rounded
! maxx212 max 1 1234567896   -> 1.23456790E+9 Inexact Rounded
! maxx213 max -1234567891  1 -> 1
! maxx214 max 1 -1234567891  -> 1
! maxx215 max -12345678901 1 -> 1
! maxx216 max 1 -12345678901 -> 1
! maxx217 max -1234567896  1 -> 1
! maxx218 max 1 -1234567896  -> 1
! 
! precision: 15
! maxx221 max 12345678000 1  -> 12345678000
! maxx222 max 1 12345678000  -> 12345678000
! maxx223 max 1234567800  1  -> 1234567800
! maxx224 max 1 1234567800   -> 1234567800
! maxx225 max 1234567890  1  -> 1234567890
! maxx226 max 1 1234567890   -> 1234567890
! maxx227 max 1234567891  1  -> 1234567891
! maxx228 max 1 1234567891   -> 1234567891
! maxx229 max 12345678901 1  -> 12345678901
! maxx230 max 1 12345678901  -> 12345678901
! maxx231 max 1234567896  1  -> 1234567896
! maxx232 max 1 1234567896   -> 1234567896
! maxx233 max -1234567891  1 -> 1
! maxx234 max 1 -1234567891  -> 1
! maxx235 max -12345678901 1 -> 1
! maxx236 max 1 -12345678901 -> 1
! maxx237 max -1234567896  1 -> 1
! maxx238 max 1 -1234567896  -> 1
! 
! -- from examples
! maxx280 max '3'   '2'  ->  '3'
! maxx281 max '-10' '3'  ->  '3'
! maxx282 max '1.0' '1'  ->  '1.0'
! maxx283 max '1' '1.0'  ->  '1'
! 
! -- overflow and underflow tests ...
! maxExponent: 999999999
! minexponent: -999999999
! maxx330 max +1.23456789012345E-0 9E+999999999 ->  9E+999999999
! maxx331 max 9E+999999999 +1.23456789012345E-0 ->  9E+999999999
! maxx332 max +0.100 9E-999999999               ->  0.100
! maxx333 max 9E-999999999 +0.100               ->  0.100
! maxx335 max -1.23456789012345E-0 9E+999999999 ->  9E+999999999
! maxx336 max 9E+999999999 -1.23456789012345E-0 ->  9E+999999999
! maxx337 max -0.100 9E-999999999               ->  9E-999999999
! maxx338 max 9E-999999999 -0.100               ->  9E-999999999
! 
! maxx339 max 1e-599999999 1e-400000001   ->  1E-400000001
! maxx340 max 1e-599999999 1e-400000000   ->  1E-400000000
! maxx341 max 1e-600000000 1e-400000000   ->  1E-400000000
! maxx342 max 9e-999999998 0.01           ->  0.01
! maxx343 max 9e-999999998 0.1            ->  0.1
! maxx344 max 0.01 9e-999999998           ->  0.01
! maxx345 max 1e599999999 1e400000001     ->  1E+599999999
! maxx346 max 1e599999999 1e400000000     ->  1E+599999999
! maxx347 max 1e600000000 1e400000000     ->  1E+600000000
! maxx348 max 9e999999998 100             ->  9E+999999998
! maxx349 max 9e999999998 10              ->  9E+999999998
! maxx350 max 100  9e999999998            ->  9E+999999998
! -- signs
! maxx351 max  1e+777777777  1e+411111111 ->  1E+777777777
! maxx352 max  1e+777777777 -1e+411111111 ->  1E+777777777
! maxx353 max -1e+777777777  1e+411111111 ->  1E+411111111
! maxx354 max -1e+777777777 -1e+411111111 -> -1E+411111111
! maxx355 max  1e-777777777  1e-411111111 ->  1E-411111111
! maxx356 max  1e-777777777 -1e-411111111 ->  1E-777777777
! maxx357 max -1e-777777777  1e-411111111 ->  1E-411111111
! maxx358 max -1e-777777777 -1e-411111111 -> -1E-777777777
! 
! 
! -- overflow tests
! maxexponent: 999999999
! minexponent: -999999999
! precision: 3
! maxx400 max 9.999E+999999999  0 ->  Infinity Inexact Overflow Rounded
! maxx401 max -9.999E+999999999 0 ->  0
! 
! -- subnormals and underflow
! precision: 3
! maxexponent: 999
! minexponent: -999
! maxx410 max  1.00E-999       0  ->   1.00E-999
! maxx411 max  0.1E-999        0  ->   1E-1000   Subnormal
! maxx412 max  0.10E-999       0  ->   1.0E-1000 Subnormal
! maxx413 max  0.100E-999      0  ->   1.0E-1000 Subnormal Rounded
! maxx414 max  0.01E-999       0  ->   1E-1001   Subnormal
! -- next is rounded to Emin
! maxx415 max  0.999E-999      0  ->   1.00E-999 Inexact Rounded Subnormal Underflow
! maxx416 max  0.099E-999      0  ->   1.0E-1000 Inexact Rounded Subnormal Underflow
! maxx417 max  0.009E-999      0  ->   1E-1001   Inexact Rounded Subnormal Underflow
! maxx418 max  0.001E-999      0  ->   0E-1001   Inexact Rounded Subnormal Underflow
! maxx419 max  0.0009E-999     0  ->   0E-1001   Inexact Rounded Subnormal Underflow
! maxx420 max  0.0001E-999     0  ->   0E-1001   Inexact Rounded Subnormal Underflow
! 
! maxx430 max -1.00E-999       0  ->   0
! maxx431 max -0.1E-999        0  ->   0
! maxx432 max -0.10E-999       0  ->   0
! maxx433 max -0.100E-999      0  ->   0
! maxx434 max -0.01E-999       0  ->   0
! maxx435 max -0.999E-999      0  ->   0
! maxx436 max -0.099E-999      0  ->   0
! maxx437 max -0.009E-999      0  ->   0
! maxx438 max -0.001E-999      0  ->   0
! maxx439 max -0.0009E-999     0  ->   0
! maxx440 max -0.0001E-999     0  ->   0
! 
! -- Null tests
! maxx900 max 10  #  -> NaN Invalid_operation
! maxx901 max  # 10  -> NaN Invalid_operation
! 
! 
! 

Index: min.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/min.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** min.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- min.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,297 ****
! ------------------------------------------------------------------------
! -- min.decTest -- decimal minimum                                     --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.35
! 
! -- we assume that base comparison is tested in compare.decTest, so
! -- these mainly cover special cases and rounding
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minexponent: -999
! 
! -- sanity checks
! mnmx001 min  -2  -2  -> -2
! mnmx002 min  -2  -1  -> -2
! mnmx003 min  -2   0  -> -2
! mnmx004 min  -2   1  -> -2
! mnmx005 min  -2   2  -> -2
! mnmx006 min  -1  -2  -> -2
! mnmx007 min  -1  -1  -> -1
! mnmx008 min  -1   0  -> -1
! mnmx009 min  -1   1  -> -1
! mnmx010 min  -1   2  -> -1
! mnmx011 min   0  -2  -> -2
! mnmx012 min   0  -1  -> -1
! mnmx013 min   0   0  ->  0
! mnmx014 min   0   1  ->  0
! mnmx015 min   0   2  ->  0
! mnmx016 min   1  -2  -> -2
! mnmx017 min   1  -1  -> -1
! mnmx018 min   1   0  ->  0
! mnmx019 min   1   1  ->  1
! mnmx020 min   1   2  ->  1
! mnmx021 min   2  -2  -> -2
! mnmx022 min   2  -1  -> -1
! mnmx023 min   2   0  ->  0
! mnmx025 min   2   1  ->  1
! mnmx026 min   2   2  ->  2
! 
! -- extended zeros
! mnmx030 min   0     0   ->  0
! mnmx031 min   0    -0   ->  0
! mnmx032 min   0    -0.0 ->  0
! mnmx033 min   0     0.0 ->  0
! mnmx034 min  -0     0   -> -0
! mnmx035 min  -0    -0   -> -0
! mnmx036 min  -0    -0.0 -> -0
! mnmx037 min  -0     0.0 -> -0
! mnmx038 min   0.0   0   ->  0.0
! mnmx039 min   0.0  -0   ->  0.0
! mnmx040 min   0.0  -0.0 ->  0.0
! mnmx041 min   0.0   0.0 ->  0.0
! mnmx042 min  -0.0   0   -> -0.0
! mnmx043 min  -0.0  -0   -> -0.0
! mnmx044 min  -0.0  -0.0 -> -0.0
! mnmx045 min  -0.0   0.0 -> -0.0
! 
! mnmx046 min  -0E1   0E2 -> -0E+1
! mnmx047 min   0E2   0E1 ->  0E+2
! mnmx048 min   0E1   0E2 ->  0E+1
! mnmx049 min  -0E3  -0E2 -> -0E+3
! 
! -- Specials
! precision: 9
! mnmx090 min  Inf  -Inf   -> -Infinity
! mnmx091 min  Inf  -1000  -> -1000
! mnmx092 min  Inf  -1     -> -1
! mnmx093 min  Inf  -0     -> -0
! mnmx094 min  Inf   0     ->  0
! mnmx095 min  Inf   1     ->  1
! mnmx096 min  Inf   1000  ->  1000
! mnmx097 min  Inf   Inf   ->  Infinity
! mnmx098 min -1000  Inf   -> -1000
! mnmx099 min -Inf   Inf   -> -Infinity
! mnmx100 min -1     Inf   -> -1
! mnmx101 min -0     Inf   -> -0
! mnmx102 min  0     Inf   ->  0
! mnmx103 min  1     Inf   ->  1
! mnmx104 min  1000  Inf   ->  1000
! mnmx105 min  Inf   Inf   ->  Infinity
! 
! mnmx120 min -Inf  -Inf   -> -Infinity
! mnmx121 min -Inf  -1000  -> -Infinity
! mnmx122 min -Inf  -1     -> -Infinity
! mnmx123 min -Inf  -0     -> -Infinity
! mnmx124 min -Inf   0     -> -Infinity
! mnmx125 min -Inf   1     -> -Infinity
! mnmx126 min -Inf   1000  -> -Infinity
! mnmx127 min -Inf   Inf   -> -Infinity
! mnmx128 min -Inf  -Inf   -> -Infinity
! mnmx129 min -1000 -Inf   -> -Infinity
! mnmx130 min -1    -Inf   -> -Infinity
! mnmx131 min -0    -Inf   -> -Infinity
! mnmx132 min  0    -Inf   -> -Infinity
! mnmx133 min  1    -Inf   -> -Infinity
! mnmx134 min  1000 -Inf   -> -Infinity
! mnmx135 min  Inf  -Inf   -> -Infinity
! 
! mnmx141 min  NaN -Inf    ->  NaN
! mnmx142 min  NaN -1000   ->  NaN
! mnmx143 min  NaN -1      ->  NaN
! mnmx144 min  NaN -0      ->  NaN
! mnmx145 min  NaN  0      ->  NaN
! mnmx146 min  NaN  1      ->  NaN
! mnmx147 min  NaN  1000   ->  NaN
! mnmx148 min  NaN  Inf    ->  NaN
! mnmx149 min  NaN  NaN    ->  NaN
! mnmx150 min -Inf  NaN    ->  NaN
! mnmx151 min -1000 NaN    ->  NaN
! mnmx152 min -1   -NaN    -> -NaN
! mnmx153 min -0    NaN    ->  NaN
! mnmx154 min  0   -NaN    -> -NaN
! mnmx155 min  1    NaN    ->  NaN
! mnmx156 min  1000 NaN    ->  NaN
! mnmx157 min  Inf  NaN    ->  NaN
! 
! mnmx161 min  sNaN -Inf   ->  NaN  Invalid_operation
! mnmx162 min  sNaN -1000  ->  NaN  Invalid_operation
! mnmx163 min  sNaN -1     ->  NaN  Invalid_operation
! mnmx164 min  sNaN -0     ->  NaN  Invalid_operation
! mnmx165 min -sNaN  0     -> -NaN  Invalid_operation
! mnmx166 min -sNaN  1     -> -NaN  Invalid_operation
! mnmx167 min  sNaN  1000  ->  NaN  Invalid_operation
! mnmx168 min  sNaN  NaN   ->  NaN  Invalid_operation
! mnmx169 min  sNaN sNaN   ->  NaN  Invalid_operation
! mnmx170 min  NaN  sNaN   ->  NaN  Invalid_operation
! mnmx171 min -Inf  sNaN   ->  NaN  Invalid_operation
! mnmx172 min -1000 sNaN   ->  NaN  Invalid_operation
! mnmx173 min -1    sNaN   ->  NaN  Invalid_operation
! mnmx174 min -0    sNaN   ->  NaN  Invalid_operation
! mnmx175 min  0    sNaN   ->  NaN  Invalid_operation
! mnmx176 min  1    sNaN   ->  NaN  Invalid_operation
! mnmx177 min  1000 sNaN   ->  NaN  Invalid_operation
! mnmx178 min  Inf  sNaN   ->  NaN  Invalid_operation
! mnmx179 min  NaN  sNaN   ->  NaN  Invalid_operation
! 
! -- propagating NaNs
! mnmx181 min  NaN9 -Inf   ->  NaN9
! mnmx182 min -NaN8  9990  -> -NaN8
! mnmx183 min  NaN71 Inf   ->  NaN71
! mnmx184 min  NaN6  NaN51 ->  NaN6
! mnmx185 min -Inf   NaN41 ->  NaN41
! mnmx186 min -9999 -NaN33 -> -NaN33
! mnmx187 min  Inf   NaN2  ->  NaN2
! 
! mnmx191 min  sNaN99 -Inf    ->  NaN99 Invalid_operation
! mnmx192 min  sNaN98 -11     ->  NaN98 Invalid_operation
! mnmx193 min -sNaN97  NaN    -> -NaN97 Invalid_operation
! mnmx194 min  sNaN69 sNaN94  ->  NaN69 Invalid_operation
! mnmx195 min  NaN95  sNaN93  ->  NaN93 Invalid_operation
! mnmx196 min -Inf    sNaN92  ->  NaN92 Invalid_operation
! mnmx197 min  088    sNaN91  ->  NaN91 Invalid_operation
! mnmx198 min  Inf   -sNaN90  -> -NaN90 Invalid_operation
! mnmx199 min  NaN    sNaN86  ->  NaN86 Invalid_operation
! 
! -- rounding checks -- chosen is rounded, or not
! maxExponent: 999
! minexponent: -999
! precision: 9
! mnmx201 min -12345678000 1  -> -1.23456780E+10 Rounded
! mnmx202 min 1 -12345678000  -> -1.23456780E+10 Rounded
! mnmx203 min -1234567800  1  -> -1.23456780E+9 Rounded
! mnmx204 min 1 -1234567800   -> -1.23456780E+9 Rounded
! mnmx205 min -1234567890  1  -> -1.23456789E+9 Rounded
! mnmx206 min 1 -1234567890   -> -1.23456789E+9 Rounded
! mnmx207 min -1234567891  1  -> -1.23456789E+9 Inexact Rounded
! mnmx208 min 1 -1234567891   -> -1.23456789E+9 Inexact Rounded
! mnmx209 min -12345678901 1  -> -1.23456789E+10 Inexact Rounded
! mnmx210 min 1 -12345678901  -> -1.23456789E+10 Inexact Rounded
! mnmx211 min -1234567896  1  -> -1.23456790E+9 Inexact Rounded
! mnmx212 min 1 -1234567896   -> -1.23456790E+9 Inexact Rounded
! mnmx213 min 1234567891  1   -> 1
! mnmx214 min 1 1234567891    -> 1
! mnmx215 min 12345678901 1   -> 1
! mnmx216 min 1 12345678901   -> 1
! mnmx217 min 1234567896  1   -> 1
! mnmx218 min 1 1234567896    -> 1
! 
! precision: 15
! mnmx221 min -12345678000 1  -> -12345678000
! mnmx222 min 1 -12345678000  -> -12345678000
! mnmx223 min -1234567800  1  -> -1234567800
! mnmx224 min 1 -1234567800   -> -1234567800
! mnmx225 min -1234567890  1  -> -1234567890
! mnmx226 min 1 -1234567890   -> -1234567890
! mnmx227 min -1234567891  1  -> -1234567891
! mnmx228 min 1 -1234567891   -> -1234567891
! mnmx229 min -12345678901 1  -> -12345678901
! mnmx230 min 1 -12345678901  -> -12345678901
! mnmx231 min -1234567896  1  -> -1234567896
! mnmx232 min 1 -1234567896   -> -1234567896
! mnmx233 min 1234567891  1   -> 1
! mnmx234 min 1 1234567891    -> 1
! mnmx235 min 12345678901 1   -> 1
! mnmx236 min 1 12345678901   -> 1
! mnmx237 min 1234567896  1   -> 1
! mnmx238 min 1 1234567896    -> 1
! 
! -- from examples
! mnmx280 min '3'   '2'  ->  '2'
! mnmx281 min '-10' '3'  ->  '-10'
! mnmx282 min '1.0' '1'  ->  '1.0'
! mnmx283 min '1' '1.0'  ->  '1'
! 
! -- overflow and underflow tests .. subnormal results [inputs] now allowed
! maxExponent: 999999999
! minexponent: -999999999
! mnmx330 min -1.23456789012345E-0 -9E+999999999 -> -9E+999999999
! mnmx331 min -9E+999999999 -1.23456789012345E-0 -> -9E+999999999
! mnmx332 min -0.100 -9E-999999999               -> -0.100
! mnmx333 min -9E-999999999 -0.100               -> -0.100
! mnmx335 min +1.23456789012345E-0 -9E+999999999 -> -9E+999999999
! mnmx336 min -9E+999999999 1.23456789012345E-0  -> -9E+999999999
! mnmx337 min +0.100 -9E-999999999               -> -9E-999999999
! mnmx338 min -9E-999999999 0.100                -> -9E-999999999
! 
! mnmx339 min -1e-599999999 -1e-400000001   ->  -1E-400000001
! mnmx340 min -1e-599999999 -1e-400000000   ->  -1E-400000000
! mnmx341 min -1e-600000000 -1e-400000000   ->  -1E-400000000
! mnmx342 min -9e-999999998 -0.01           ->  -0.01
! mnmx343 min -9e-999999998 -0.1            ->  -0.1
! mnmx344 min -0.01         -9e-999999998   ->  -0.01
! mnmx345 min -1e599999999  -1e400000001    ->  -1E+599999999
! mnmx346 min -1e599999999  -1e400000000    ->  -1E+599999999
! mnmx347 min -1e600000000  -1e400000000    ->  -1E+600000000
! mnmx348 min -9e999999998  -100            ->  -9E+999999998
! mnmx349 min -9e999999998  -10             ->  -9E+999999998
! mnmx350 min -100          -9e999999998    ->  -9E+999999998
! -- signs
! mnmx351 min -1e+777777777 -1e+411111111 -> -1E+777777777
! mnmx352 min -1e+777777777 +1e+411111111 -> -1E+777777777
! mnmx353 min +1e+777777777 -1e+411111111 -> -1E+411111111
! mnmx354 min +1e+777777777 +1e+411111111 ->  1E+411111111
! mnmx355 min -1e-777777777 -1e-411111111 -> -1E-411111111
! mnmx356 min -1e-777777777 +1e-411111111 -> -1E-777777777
! mnmx357 min +1e-777777777 -1e-411111111 -> -1E-411111111
! mnmx358 min +1e-777777777 +1e-411111111 ->  1E-777777777
! 
! 
! -- overflow tests
! maxexponent: 999999999
! minexponent: -999999999
! precision: 3
! mnmx400 min 9.999E+999999999  0 ->  0
! mnmx401 min -9.999E+999999999 0 -> -Infinity Inexact Overflow Rounded
! 
! -- subnormals and underflow
! precision: 3
! maxexponent: 999
! minexponent: -999
! mnmx410 min  1.00E-999       0  ->   0
! mnmx411 min  0.1E-999        0  ->   0
! mnmx412 min  0.10E-999       0  ->   0
! mnmx413 min  0.100E-999      0  ->   0
! mnmx414 min  0.01E-999       0  ->   0
! mnmx415 min  0.999E-999      0  ->   0
! mnmx416 min  0.099E-999      0  ->   0
! mnmx417 min  0.009E-999      0  ->   0
! mnmx418 min  0.001E-999      0  ->   0
! mnmx419 min  0.0009E-999     0  ->   0
! mnmx420 min  0.0001E-999     0  ->   0
! 
! mnmx430 min -1.00E-999       0  ->  -1.00E-999
! mnmx431 min -0.1E-999        0  ->  -1E-1000   Subnormal
! mnmx432 min -0.10E-999       0  ->  -1.0E-1000 Subnormal
! mnmx433 min -0.100E-999      0  ->  -1.0E-1000 Subnormal Rounded
! mnmx434 min -0.01E-999       0  ->  -1E-1001   Subnormal
! -- next is rounded to Emin
! mnmx435 min -0.999E-999      0  ->  -1.00E-999 Inexact Rounded Subnormal Underflow
! mnmx436 min -0.099E-999      0  ->  -1.0E-1000 Inexact Rounded Subnormal Underflow
! mnmx437 min -0.009E-999      0  ->  -1E-1001   Inexact Rounded Subnormal Underflow
! mnmx438 min -0.001E-999      0  ->  -0E-1001   Inexact Rounded Subnormal Underflow
! mnmx439 min -0.0009E-999     0  ->  -0E-1001   Inexact Rounded Subnormal Underflow
! mnmx440 min -0.0001E-999     0  ->  -0E-1001   Inexact Rounded Subnormal Underflow
! 
! 
! -- Null tests
! mnm900 min 10  # -> NaN Invalid_operation
! mnm901 min  # 10 -> NaN Invalid_operation
--- 1,297 ----
! ------------------------------------------------------------------------
! -- min.decTest -- decimal minimum                                     --
! -- Copyright (c) IBM Corporation, 1981, 2004.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.38
! 
! -- we assume that base comparison is tested in compare.decTest, so
! -- these mainly cover special cases and rounding
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 384
! minexponent: -383
! 
! -- sanity checks
! mnmx001 min  -2  -2  -> -2
! mnmx002 min  -2  -1  -> -2
! mnmx003 min  -2   0  -> -2
! mnmx004 min  -2   1  -> -2
! mnmx005 min  -2   2  -> -2
! mnmx006 min  -1  -2  -> -2
! mnmx007 min  -1  -1  -> -1
! mnmx008 min  -1   0  -> -1
! mnmx009 min  -1   1  -> -1
! mnmx010 min  -1   2  -> -1
! mnmx011 min   0  -2  -> -2
! mnmx012 min   0  -1  -> -1
! mnmx013 min   0   0  ->  0
! mnmx014 min   0   1  ->  0
! mnmx015 min   0   2  ->  0
! mnmx016 min   1  -2  -> -2
! mnmx017 min   1  -1  -> -1
! mnmx018 min   1   0  ->  0
! mnmx019 min   1   1  ->  1
! mnmx020 min   1   2  ->  1
! mnmx021 min   2  -2  -> -2
! mnmx022 min   2  -1  -> -1
! mnmx023 min   2   0  ->  0
! mnmx025 min   2   1  ->  1
! mnmx026 min   2   2  ->  2
! 
! -- extended zeros
! mnmx030 min   0     0   ->  0
! mnmx031 min   0    -0   ->  0
! mnmx032 min   0    -0.0 ->  0
! mnmx033 min   0     0.0 ->  0
! mnmx034 min  -0     0   -> -0
! mnmx035 min  -0    -0   -> -0
! mnmx036 min  -0    -0.0 -> -0
! mnmx037 min  -0     0.0 -> -0
! mnmx038 min   0.0   0   ->  0.0
! mnmx039 min   0.0  -0   ->  0.0
! mnmx040 min   0.0  -0.0 ->  0.0
! mnmx041 min   0.0   0.0 ->  0.0
! mnmx042 min  -0.0   0   -> -0.0
! mnmx043 min  -0.0  -0   -> -0.0
! mnmx044 min  -0.0  -0.0 -> -0.0
! mnmx045 min  -0.0   0.0 -> -0.0
! 
! mnmx046 min  -0E1   0E2 -> -0E+1
! mnmx047 min   0E2   0E1 ->  0E+2
! mnmx048 min   0E1   0E2 ->  0E+1
! mnmx049 min  -0E3  -0E2 -> -0E+3
! 
! -- Specials
! precision: 9
! mnmx090 min  Inf  -Inf   -> -Infinity
! mnmx091 min  Inf  -1000  -> -1000
! mnmx092 min  Inf  -1     -> -1
! mnmx093 min  Inf  -0     -> -0
! mnmx094 min  Inf   0     ->  0
! mnmx095 min  Inf   1     ->  1
! mnmx096 min  Inf   1000  ->  1000
! mnmx097 min  Inf   Inf   ->  Infinity
! mnmx098 min -1000  Inf   -> -1000
! mnmx099 min -Inf   Inf   -> -Infinity
! mnmx100 min -1     Inf   -> -1
! mnmx101 min -0     Inf   -> -0
! mnmx102 min  0     Inf   ->  0
! mnmx103 min  1     Inf   ->  1
! mnmx104 min  1000  Inf   ->  1000
! mnmx105 min  Inf   Inf   ->  Infinity
! 
! mnmx120 min -Inf  -Inf   -> -Infinity
! mnmx121 min -Inf  -1000  -> -Infinity
! mnmx122 min -Inf  -1     -> -Infinity
! mnmx123 min -Inf  -0     -> -Infinity
! mnmx124 min -Inf   0     -> -Infinity
! mnmx125 min -Inf   1     -> -Infinity
! mnmx126 min -Inf   1000  -> -Infinity
! mnmx127 min -Inf   Inf   -> -Infinity
! mnmx128 min -Inf  -Inf   -> -Infinity
! mnmx129 min -1000 -Inf   -> -Infinity
! mnmx130 min -1    -Inf   -> -Infinity
! mnmx131 min -0    -Inf   -> -Infinity
! mnmx132 min  0    -Inf   -> -Infinity
! mnmx133 min  1    -Inf   -> -Infinity
! mnmx134 min  1000 -Inf   -> -Infinity
! mnmx135 min  Inf  -Inf   -> -Infinity
! 
! mnmx141 min  NaN -Inf    ->  NaN
! mnmx142 min  NaN -1000   ->  NaN
! mnmx143 min  NaN -1      ->  NaN
! mnmx144 min  NaN -0      ->  NaN
! mnmx145 min  NaN  0      ->  NaN
! mnmx146 min  NaN  1      ->  NaN
! mnmx147 min  NaN  1000   ->  NaN
! mnmx148 min  NaN  Inf    ->  NaN
! mnmx149 min  NaN  NaN    ->  NaN
! mnmx150 min -Inf  NaN    ->  NaN
! mnmx151 min -1000 NaN    ->  NaN
! mnmx152 min -1   -NaN    -> -NaN
! mnmx153 min -0    NaN    ->  NaN
! mnmx154 min  0   -NaN    -> -NaN
! mnmx155 min  1    NaN    ->  NaN
! mnmx156 min  1000 NaN    ->  NaN
! mnmx157 min  Inf  NaN    ->  NaN
! 
! mnmx161 min  sNaN -Inf   ->  NaN  Invalid_operation
! mnmx162 min  sNaN -1000  ->  NaN  Invalid_operation
! mnmx163 min  sNaN -1     ->  NaN  Invalid_operation
! mnmx164 min  sNaN -0     ->  NaN  Invalid_operation
! mnmx165 min -sNaN  0     -> -NaN  Invalid_operation
! mnmx166 min -sNaN  1     -> -NaN  Invalid_operation
! mnmx167 min  sNaN  1000  ->  NaN  Invalid_operation
! mnmx168 min  sNaN  NaN   ->  NaN  Invalid_operation
! mnmx169 min  sNaN sNaN   ->  NaN  Invalid_operation
! mnmx170 min  NaN  sNaN   ->  NaN  Invalid_operation
! mnmx171 min -Inf  sNaN   ->  NaN  Invalid_operation
! mnmx172 min -1000 sNaN   ->  NaN  Invalid_operation
! mnmx173 min -1    sNaN   ->  NaN  Invalid_operation
! mnmx174 min -0    sNaN   ->  NaN  Invalid_operation
! mnmx175 min  0    sNaN   ->  NaN  Invalid_operation
! mnmx176 min  1    sNaN   ->  NaN  Invalid_operation
! mnmx177 min  1000 sNaN   ->  NaN  Invalid_operation
! mnmx178 min  Inf  sNaN   ->  NaN  Invalid_operation
! mnmx179 min  NaN  sNaN   ->  NaN  Invalid_operation
! 
! -- propagating NaNs
! mnmx181 min  NaN9 -Inf   ->  NaN9
! mnmx182 min -NaN8  9990  -> -NaN8
! mnmx183 min  NaN71 Inf   ->  NaN71
! mnmx184 min  NaN6  NaN51 ->  NaN6
! mnmx185 min -Inf   NaN41 ->  NaN41
! mnmx186 min -9999 -NaN33 -> -NaN33
! mnmx187 min  Inf   NaN2  ->  NaN2
! 
! mnmx191 min  sNaN99 -Inf    ->  NaN99 Invalid_operation
! mnmx192 min  sNaN98 -11     ->  NaN98 Invalid_operation
! mnmx193 min -sNaN97  NaN    -> -NaN97 Invalid_operation
! mnmx194 min  sNaN69 sNaN94  ->  NaN69 Invalid_operation
! mnmx195 min  NaN95  sNaN93  ->  NaN93 Invalid_operation
! mnmx196 min -Inf    sNaN92  ->  NaN92 Invalid_operation
! mnmx197 min  088    sNaN91  ->  NaN91 Invalid_operation
! mnmx198 min  Inf   -sNaN90  -> -NaN90 Invalid_operation
! mnmx199 min  NaN    sNaN86  ->  NaN86 Invalid_operation
! 
! -- rounding checks -- chosen is rounded, or not
! maxExponent: 999
! minexponent: -999
! precision: 9
! mnmx201 min -12345678000 1  -> -1.23456780E+10 Rounded
! mnmx202 min 1 -12345678000  -> -1.23456780E+10 Rounded
! mnmx203 min -1234567800  1  -> -1.23456780E+9 Rounded
! mnmx204 min 1 -1234567800   -> -1.23456780E+9 Rounded
! mnmx205 min -1234567890  1  -> -1.23456789E+9 Rounded
! mnmx206 min 1 -1234567890   -> -1.23456789E+9 Rounded
! mnmx207 min -1234567891  1  -> -1.23456789E+9 Inexact Rounded
! mnmx208 min 1 -1234567891   -> -1.23456789E+9 Inexact Rounded
! mnmx209 min -12345678901 1  -> -1.23456789E+10 Inexact Rounded
! mnmx210 min 1 -12345678901  -> -1.23456789E+10 Inexact Rounded
! mnmx211 min -1234567896  1  -> -1.23456790E+9 Inexact Rounded
! mnmx212 min 1 -1234567896   -> -1.23456790E+9 Inexact Rounded
! mnmx213 min 1234567891  1   -> 1
! mnmx214 min 1 1234567891    -> 1
! mnmx215 min 12345678901 1   -> 1
! mnmx216 min 1 12345678901   -> 1
! mnmx217 min 1234567896  1   -> 1
! mnmx218 min 1 1234567896    -> 1
! 
! precision: 15
! mnmx221 min -12345678000 1  -> -12345678000
! mnmx222 min 1 -12345678000  -> -12345678000
! mnmx223 min -1234567800  1  -> -1234567800
! mnmx224 min 1 -1234567800   -> -1234567800
! mnmx225 min -1234567890  1  -> -1234567890
! mnmx226 min 1 -1234567890   -> -1234567890
! mnmx227 min -1234567891  1  -> -1234567891
! mnmx228 min 1 -1234567891   -> -1234567891
! mnmx229 min -12345678901 1  -> -12345678901
! mnmx230 min 1 -12345678901  -> -12345678901
! mnmx231 min -1234567896  1  -> -1234567896
! mnmx232 min 1 -1234567896   -> -1234567896
! mnmx233 min 1234567891  1   -> 1
! mnmx234 min 1 1234567891    -> 1
! mnmx235 min 12345678901 1   -> 1
! mnmx236 min 1 12345678901   -> 1
! mnmx237 min 1234567896  1   -> 1
! mnmx238 min 1 1234567896    -> 1
! 
! -- from examples
! mnmx280 min '3'   '2'  ->  '2'
! mnmx281 min '-10' '3'  ->  '-10'
! mnmx282 min '1.0' '1'  ->  '1.0'
! mnmx283 min '1' '1.0'  ->  '1'
! 
! -- overflow and underflow tests .. subnormal results [inputs] now allowed
! maxExponent: 999999999
! minexponent: -999999999
! mnmx330 min -1.23456789012345E-0 -9E+999999999 -> -9E+999999999
! mnmx331 min -9E+999999999 -1.23456789012345E-0 -> -9E+999999999
! mnmx332 min -0.100 -9E-999999999               -> -0.100
! mnmx333 min -9E-999999999 -0.100               -> -0.100
! mnmx335 min +1.23456789012345E-0 -9E+999999999 -> -9E+999999999
! mnmx336 min -9E+999999999 1.23456789012345E-0  -> -9E+999999999
! mnmx337 min +0.100 -9E-999999999               -> -9E-999999999
! mnmx338 min -9E-999999999 0.100                -> -9E-999999999
! 
! mnmx339 min -1e-599999999 -1e-400000001   ->  -1E-400000001
! mnmx340 min -1e-599999999 -1e-400000000   ->  -1E-400000000
! mnmx341 min -1e-600000000 -1e-400000000   ->  -1E-400000000
! mnmx342 min -9e-999999998 -0.01           ->  -0.01
! mnmx343 min -9e-999999998 -0.1            ->  -0.1
! mnmx344 min -0.01         -9e-999999998   ->  -0.01
! mnmx345 min -1e599999999  -1e400000001    ->  -1E+599999999
! mnmx346 min -1e599999999  -1e400000000    ->  -1E+599999999
! mnmx347 min -1e600000000  -1e400000000    ->  -1E+600000000
! mnmx348 min -9e999999998  -100            ->  -9E+999999998
! mnmx349 min -9e999999998  -10             ->  -9E+999999998
! mnmx350 min -100          -9e999999998    ->  -9E+999999998
! -- signs
! mnmx351 min -1e+777777777 -1e+411111111 -> -1E+777777777
! mnmx352 min -1e+777777777 +1e+411111111 -> -1E+777777777
! mnmx353 min +1e+777777777 -1e+411111111 -> -1E+411111111
! mnmx354 min +1e+777777777 +1e+411111111 ->  1E+411111111
! mnmx355 min -1e-777777777 -1e-411111111 -> -1E-411111111
! mnmx356 min -1e-777777777 +1e-411111111 -> -1E-777777777
! mnmx357 min +1e-777777777 -1e-411111111 -> -1E-411111111
! mnmx358 min +1e-777777777 +1e-411111111 ->  1E-777777777
! 
! 
! -- overflow tests
! maxexponent: 999999999
! minexponent: -999999999
! precision: 3
! mnmx400 min 9.999E+999999999  0 ->  0
! mnmx401 min -9.999E+999999999 0 -> -Infinity Inexact Overflow Rounded
! 
! -- subnormals and underflow
! precision: 3
! maxexponent: 999
! minexponent: -999
! mnmx410 min  1.00E-999       0  ->   0
! mnmx411 min  0.1E-999        0  ->   0
! mnmx412 min  0.10E-999       0  ->   0
! mnmx413 min  0.100E-999      0  ->   0
! mnmx414 min  0.01E-999       0  ->   0
! mnmx415 min  0.999E-999      0  ->   0
! mnmx416 min  0.099E-999      0  ->   0
! mnmx417 min  0.009E-999      0  ->   0
! mnmx418 min  0.001E-999      0  ->   0
! mnmx419 min  0.0009E-999     0  ->   0
! mnmx420 min  0.0001E-999     0  ->   0
! 
! mnmx430 min -1.00E-999       0  ->  -1.00E-999
! mnmx431 min -0.1E-999        0  ->  -1E-1000   Subnormal
! mnmx432 min -0.10E-999       0  ->  -1.0E-1000 Subnormal
! mnmx433 min -0.100E-999      0  ->  -1.0E-1000 Subnormal Rounded
! mnmx434 min -0.01E-999       0  ->  -1E-1001   Subnormal
! -- next is rounded to Emin
! mnmx435 min -0.999E-999      0  ->  -1.00E-999 Inexact Rounded Subnormal Underflow
! mnmx436 min -0.099E-999      0  ->  -1.0E-1000 Inexact Rounded Subnormal Underflow
! mnmx437 min -0.009E-999      0  ->  -1E-1001   Inexact Rounded Subnormal Underflow
! mnmx438 min -0.001E-999      0  ->  -0E-1001   Inexact Rounded Subnormal Underflow
! mnmx439 min -0.0009E-999     0  ->  -0E-1001   Inexact Rounded Subnormal Underflow
! mnmx440 min -0.0001E-999     0  ->  -0E-1001   Inexact Rounded Subnormal Underflow
! 
! 
! -- Null tests
! mnm900 min 10  # -> NaN Invalid_operation
! mnm901 min  # 10 -> NaN Invalid_operation

Index: minus.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/minus.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** minus.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- minus.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,182 ****
! ------------------------------------------------------------------------
! -- minus.decTest -- decimal negation                                  --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.35
! 
! -- This set of tests primarily tests the existence of the operator.
! -- Subtraction, rounding, and more overflows are tested elsewhere.
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minexponent: -999
! 
! minx001 minus '1'      -> '-1'
! minx002 minus '-1'     -> '1'
! minx003 minus '1.00'   -> '-1.00'
! minx004 minus '-1.00'  -> '1.00'
! minx005 minus '0'      -> '0'
! minx006 minus '0.00'   -> '0.00'
! minx007 minus '00.0'   -> '0.0'
! minx008 minus '00.00'  -> '0.00'
! minx009 minus '00'     -> '0'
! 
! minx010 minus '-2'     -> '2'
! minx011 minus '2'      -> '-2'
! minx012 minus '-2.00'  -> '2.00'
! minx013 minus '2.00'   -> '-2.00'
! minx014 minus '-0'     -> '0'
! minx015 minus '-0.00'  -> '0.00'
! minx016 minus '-00.0'  -> '0.0'
! minx017 minus '-00.00' -> '0.00'
! minx018 minus '-00'    -> '0'
! 
! -- "lhs" zeros in plus and minus have exponent = operand
! minx020 minus '-0E3'   -> '0E+3'
! minx021 minus '-0E2'   -> '0E+2'
! minx022 minus '-0E1'   -> '0E+1'
! minx023 minus '-0E0'   -> '0'
! minx024 minus '+0E0'   -> '0'
! minx025 minus '+0E1'   -> '0E+1'
! minx026 minus '+0E2'   -> '0E+2'
! minx027 minus '+0E3'   -> '0E+3'
! 
! minx030 minus '-5E3'   -> '5E+3'
! minx031 minus '-5E8'   -> '5E+8'
! minx032 minus '-5E13'  -> '5E+13'
! minx033 minus '-5E18'  -> '5E+18'
! minx034 minus '+5E3'   -> '-5E+3'
! minx035 minus '+5E8'   -> '-5E+8'
! minx036 minus '+5E13'  -> '-5E+13'
! minx037 minus '+5E18'  -> '-5E+18'
! 
! minx050 minus '-2000000' -> '2000000'
! minx051 minus '2000000'  -> '-2000000'
! precision: 7
! minx052 minus '-2000000' -> '2000000'
! minx053 minus '2000000'  -> '-2000000'
! precision: 6
! minx054 minus '-2000000' -> '2.00000E+6' Rounded
! minx055 minus '2000000'  -> '-2.00000E+6' Rounded
! precision: 3
! minx056 minus '-2000000' -> '2.00E+6' Rounded
! minx057 minus '2000000'  -> '-2.00E+6' Rounded
! 
! -- more fixed, potential LHS swaps/overlays if done by 0 subtract x
! precision: 9
! minx060 minus '56267E-10'   -> '-0.0000056267'
! minx061 minus '56267E-5'    -> '-0.56267'
! minx062 minus '56267E-2'    -> '-562.67'
! minx063 minus '56267E-1'    -> '-5626.7'
! minx065 minus '56267E-0'    -> '-56267'
! minx066 minus '56267E+0'    -> '-56267'
! minx067 minus '56267E+1'    -> '-5.6267E+5'
! minx068 minus '56267E+2'    -> '-5.6267E+6'
! minx069 minus '56267E+3'    -> '-5.6267E+7'
! minx070 minus '56267E+4'    -> '-5.6267E+8'
! minx071 minus '56267E+5'    -> '-5.6267E+9'
! minx072 minus '56267E+6'    -> '-5.6267E+10'
! minx080 minus '-56267E-10'  -> '0.0000056267'
! minx081 minus '-56267E-5'   -> '0.56267'
! minx082 minus '-56267E-2'   -> '562.67'
! minx083 minus '-56267E-1'   -> '5626.7'
! minx085 minus '-56267E-0'   -> '56267'
! minx086 minus '-56267E+0'   -> '56267'
! minx087 minus '-56267E+1'   -> '5.6267E+5'
! minx088 minus '-56267E+2'   -> '5.6267E+6'
! minx089 minus '-56267E+3'   -> '5.6267E+7'
! minx090 minus '-56267E+4'   -> '5.6267E+8'
! minx091 minus '-56267E+5'   -> '5.6267E+9'
! minx092 minus '-56267E+6'   -> '5.6267E+10'
! 
! 
! -- overflow tests
! maxexponent: 999999999
! minexponent: -999999999
! precision: 3
! minx100 minus 9.999E+999999999  -> -Infinity Inexact Overflow Rounded
! minx101 minus -9.999E+999999999 ->  Infinity Inexact Overflow Rounded
! 
! -- subnormals and underflow
! precision: 3
! maxexponent: 999
! minexponent: -999
! minx110 minus  1.00E-999        ->  -1.00E-999
! minx111 minus  0.1E-999         ->  -1E-1000   Subnormal
! minx112 minus  0.10E-999        ->  -1.0E-1000 Subnormal
! minx113 minus  0.100E-999       ->  -1.0E-1000 Subnormal Rounded
! minx114 minus  0.01E-999        ->  -1E-1001   Subnormal
! -- next is rounded to Emin
! minx115 minus  0.999E-999       ->  -1.00E-999 Inexact Rounded Subnormal Underflow
! minx116 minus  0.099E-999       ->  -1.0E-1000 Inexact Rounded Subnormal Underflow
! minx117 minus  0.009E-999       ->  -1E-1001   Inexact Rounded Subnormal Underflow
! minx118 minus  0.001E-999       ->  -0E-1001   Inexact Rounded Subnormal Underflow
! minx119 minus  0.0009E-999      ->  -0E-1001   Inexact Rounded Subnormal Underflow
! minx120 minus  0.0001E-999      ->  -0E-1001   Inexact Rounded Subnormal Underflow
! 
! minx130 minus -1.00E-999        ->   1.00E-999
! minx131 minus -0.1E-999         ->   1E-1000   Subnormal
! minx132 minus -0.10E-999        ->   1.0E-1000 Subnormal
! minx133 minus -0.100E-999       ->   1.0E-1000 Subnormal Rounded
! minx134 minus -0.01E-999        ->   1E-1001   Subnormal
! -- next is rounded to Emin
! minx135 minus -0.999E-999       ->   1.00E-999 Inexact Rounded Subnormal Underflow
! minx136 minus -0.099E-999       ->   1.0E-1000 Inexact Rounded Subnormal Underflow
! minx137 minus -0.009E-999       ->   1E-1001   Inexact Rounded Subnormal Underflow
! minx138 minus -0.001E-999       ->   0E-1001   Inexact Rounded Subnormal Underflow
! minx139 minus -0.0009E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! minx140 minus -0.0001E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! 
! 
! -- long operand checks
! maxexponent: 999
! minexponent: -999
! precision: 9
! minx301 minus 12345678000  -> -1.23456780E+10 Rounded
! minx302 minus 1234567800   -> -1.23456780E+9 Rounded
! minx303 minus 1234567890   -> -1.23456789E+9 Rounded
! minx304 minus 1234567891   -> -1.23456789E+9 Inexact Rounded
! minx305 minus 12345678901  -> -1.23456789E+10 Inexact Rounded
! minx306 minus 1234567896   -> -1.23456790E+9 Inexact Rounded
! 
! precision: 15
! -- still checking
! minx321 minus 12345678000  -> -12345678000
! minx322 minus 1234567800   -> -1234567800
! minx323 minus 1234567890   -> -1234567890
! minx324 minus 1234567891   -> -1234567891
! minx325 minus 12345678901  -> -12345678901
! minx326 minus 1234567896   -> -1234567896
! 
! -- specials
! minx420 minus 'Inf'    -> '-Infinity'
! minx421 minus '-Inf'   -> 'Infinity'
! minx422 minus   NaN    ->  NaN
! minx423 minus  sNaN    ->  NaN    Invalid_operation
! minx424 minus   NaN255 ->  NaN255
! minx425 minus  sNaN256 ->  NaN256 Invalid_operation
! minx426 minus  -NaN    -> -NaN
! minx427 minus -sNaN    -> -NaN    Invalid_operation
! minx428 minus  -NaN255 -> -NaN255
! minx429 minus -sNaN256 -> -NaN256 Invalid_operation
! 
! -- Null tests
! minx900 minus  # -> NaN Invalid_operation
! 
--- 1,182 ----
! ------------------------------------------------------------------------
! -- minus.decTest -- decimal negation                                  --
! -- Copyright (c) IBM Corporation, 1981, 2004.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.38
! 
! -- This set of tests primarily tests the existence of the operator.
! -- Subtraction, rounding, and more overflows are tested elsewhere.
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 384
! minexponent: -383
! 
! minx001 minus '1'      -> '-1'
! minx002 minus '-1'     -> '1'
! minx003 minus '1.00'   -> '-1.00'
! minx004 minus '-1.00'  -> '1.00'
! minx005 minus '0'      -> '0'
! minx006 minus '0.00'   -> '0.00'
! minx007 minus '00.0'   -> '0.0'
! minx008 minus '00.00'  -> '0.00'
! minx009 minus '00'     -> '0'
! 
! minx010 minus '-2'     -> '2'
! minx011 minus '2'      -> '-2'
! minx012 minus '-2.00'  -> '2.00'
! minx013 minus '2.00'   -> '-2.00'
! minx014 minus '-0'     -> '0'
! minx015 minus '-0.00'  -> '0.00'
! minx016 minus '-00.0'  -> '0.0'
! minx017 minus '-00.00' -> '0.00'
! minx018 minus '-00'    -> '0'
! 
! -- "lhs" zeros in plus and minus have exponent = operand
! minx020 minus '-0E3'   -> '0E+3'
! minx021 minus '-0E2'   -> '0E+2'
! minx022 minus '-0E1'   -> '0E+1'
! minx023 minus '-0E0'   -> '0'
! minx024 minus '+0E0'   -> '0'
! minx025 minus '+0E1'   -> '0E+1'
! minx026 minus '+0E2'   -> '0E+2'
! minx027 minus '+0E3'   -> '0E+3'
! 
! minx030 minus '-5E3'   -> '5E+3'
! minx031 minus '-5E8'   -> '5E+8'
! minx032 minus '-5E13'  -> '5E+13'
! minx033 minus '-5E18'  -> '5E+18'
! minx034 minus '+5E3'   -> '-5E+3'
! minx035 minus '+5E8'   -> '-5E+8'
! minx036 minus '+5E13'  -> '-5E+13'
! minx037 minus '+5E18'  -> '-5E+18'
! 
! minx050 minus '-2000000' -> '2000000'
! minx051 minus '2000000'  -> '-2000000'
! precision: 7
! minx052 minus '-2000000' -> '2000000'
! minx053 minus '2000000'  -> '-2000000'
! precision: 6
! minx054 minus '-2000000' -> '2.00000E+6' Rounded
! minx055 minus '2000000'  -> '-2.00000E+6' Rounded
! precision: 3
! minx056 minus '-2000000' -> '2.00E+6' Rounded
! minx057 minus '2000000'  -> '-2.00E+6' Rounded
! 
! -- more fixed, potential LHS swaps/overlays if done by 0 subtract x
! precision: 9
! minx060 minus '56267E-10'   -> '-0.0000056267'
! minx061 minus '56267E-5'    -> '-0.56267'
! minx062 minus '56267E-2'    -> '-562.67'
! minx063 minus '56267E-1'    -> '-5626.7'
! minx065 minus '56267E-0'    -> '-56267'
! minx066 minus '56267E+0'    -> '-56267'
! minx067 minus '56267E+1'    -> '-5.6267E+5'
! minx068 minus '56267E+2'    -> '-5.6267E+6'
! minx069 minus '56267E+3'    -> '-5.6267E+7'
! minx070 minus '56267E+4'    -> '-5.6267E+8'
! minx071 minus '56267E+5'    -> '-5.6267E+9'
! minx072 minus '56267E+6'    -> '-5.6267E+10'
! minx080 minus '-56267E-10'  -> '0.0000056267'
! minx081 minus '-56267E-5'   -> '0.56267'
! minx082 minus '-56267E-2'   -> '562.67'
! minx083 minus '-56267E-1'   -> '5626.7'
! minx085 minus '-56267E-0'   -> '56267'
! minx086 minus '-56267E+0'   -> '56267'
! minx087 minus '-56267E+1'   -> '5.6267E+5'
! minx088 minus '-56267E+2'   -> '5.6267E+6'
! minx089 minus '-56267E+3'   -> '5.6267E+7'
! minx090 minus '-56267E+4'   -> '5.6267E+8'
! minx091 minus '-56267E+5'   -> '5.6267E+9'
! minx092 minus '-56267E+6'   -> '5.6267E+10'
! 
! 
! -- overflow tests
! maxexponent: 999999999
! minexponent: -999999999
! precision: 3
! minx100 minus 9.999E+999999999  -> -Infinity Inexact Overflow Rounded
! minx101 minus -9.999E+999999999 ->  Infinity Inexact Overflow Rounded
! 
! -- subnormals and underflow
! precision: 3
! maxexponent: 999
! minexponent: -999
! minx110 minus  1.00E-999        ->  -1.00E-999
! minx111 minus  0.1E-999         ->  -1E-1000   Subnormal
! minx112 minus  0.10E-999        ->  -1.0E-1000 Subnormal
! minx113 minus  0.100E-999       ->  -1.0E-1000 Subnormal Rounded
! minx114 minus  0.01E-999        ->  -1E-1001   Subnormal
! -- next is rounded to Emin
! minx115 minus  0.999E-999       ->  -1.00E-999 Inexact Rounded Subnormal Underflow
! minx116 minus  0.099E-999       ->  -1.0E-1000 Inexact Rounded Subnormal Underflow
! minx117 minus  0.009E-999       ->  -1E-1001   Inexact Rounded Subnormal Underflow
! minx118 minus  0.001E-999       ->  -0E-1001   Inexact Rounded Subnormal Underflow
! minx119 minus  0.0009E-999      ->  -0E-1001   Inexact Rounded Subnormal Underflow
! minx120 minus  0.0001E-999      ->  -0E-1001   Inexact Rounded Subnormal Underflow
! 
! minx130 minus -1.00E-999        ->   1.00E-999
! minx131 minus -0.1E-999         ->   1E-1000   Subnormal
! minx132 minus -0.10E-999        ->   1.0E-1000 Subnormal
! minx133 minus -0.100E-999       ->   1.0E-1000 Subnormal Rounded
! minx134 minus -0.01E-999        ->   1E-1001   Subnormal
! -- next is rounded to Emin
! minx135 minus -0.999E-999       ->   1.00E-999 Inexact Rounded Subnormal Underflow
! minx136 minus -0.099E-999       ->   1.0E-1000 Inexact Rounded Subnormal Underflow
! minx137 minus -0.009E-999       ->   1E-1001   Inexact Rounded Subnormal Underflow
! minx138 minus -0.001E-999       ->   0E-1001   Inexact Rounded Subnormal Underflow
! minx139 minus -0.0009E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! minx140 minus -0.0001E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! 
! 
! -- long operand checks
! maxexponent: 999
! minexponent: -999
! precision: 9
! minx301 minus 12345678000  -> -1.23456780E+10 Rounded
! minx302 minus 1234567800   -> -1.23456780E+9 Rounded
! minx303 minus 1234567890   -> -1.23456789E+9 Rounded
! minx304 minus 1234567891   -> -1.23456789E+9 Inexact Rounded
! minx305 minus 12345678901  -> -1.23456789E+10 Inexact Rounded
! minx306 minus 1234567896   -> -1.23456790E+9 Inexact Rounded
! 
! precision: 15
! -- still checking
! minx321 minus 12345678000  -> -12345678000
! minx322 minus 1234567800   -> -1234567800
! minx323 minus 1234567890   -> -1234567890
! minx324 minus 1234567891   -> -1234567891
! minx325 minus 12345678901  -> -12345678901
! minx326 minus 1234567896   -> -1234567896
! 
! -- specials
! minx420 minus 'Inf'    -> '-Infinity'
! minx421 minus '-Inf'   -> 'Infinity'
! minx422 minus   NaN    ->  NaN
! minx423 minus  sNaN    ->  NaN    Invalid_operation
! minx424 minus   NaN255 ->  NaN255
! minx425 minus  sNaN256 ->  NaN256 Invalid_operation
! minx426 minus  -NaN    -> -NaN
! minx427 minus -sNaN    -> -NaN    Invalid_operation
! minx428 minus  -NaN255 -> -NaN255
! minx429 minus -sNaN256 -> -NaN256 Invalid_operation
! 
! -- Null tests
! minx900 minus  # -> NaN Invalid_operation
! 

Index: multiply.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/multiply.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** multiply.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- multiply.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,651 ****
! ------------------------------------------------------------------------
! -- multiply.decTest -- decimal multiplication                         --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
[...1273 lines suppressed...]
! mulx881 multiply  1.2347E-40  1.2347E-40  ->  1.524E-80 Inexact Rounded Subnormal Underflow
! mulx882 multiply  1.234E-40  1.234E-40  ->  1.523E-80 Inexact Rounded Subnormal Underflow
! mulx883 multiply  1.23E-40   1.23E-40   ->  1.513E-80 Inexact Rounded Subnormal Underflow
! mulx884 multiply  1.2E-40    1.2E-40    ->  1.44E-80  Subnormal
! mulx885 multiply  1.2E-40    1.2E-41    ->  1.44E-81  Subnormal
! mulx886 multiply  1.2E-40    1.2E-42    ->  1.4E-82   Subnormal Inexact Rounded Underflow
! mulx887 multiply  1.2E-40    1.3E-42    ->  1.6E-82   Subnormal Inexact Rounded Underflow
! mulx888 multiply  1.3E-40    1.3E-42    ->  1.7E-82   Subnormal Inexact Rounded Underflow
! 
! mulx891 multiply  1.2345E-39   1.234E-40  ->  1.5234E-79 Inexact Rounded
! mulx892 multiply  1.23456E-39  1.234E-40  ->  1.5234E-79 Inexact Rounded
! mulx893 multiply  1.2345E-40   1.234E-40  ->  1.523E-80  Inexact Rounded Subnormal Underflow
! mulx894 multiply  1.23456E-40  1.234E-40  ->  1.523E-80  Inexact Rounded Subnormal Underflow
! mulx895 multiply  1.2345E-41   1.234E-40  ->  1.52E-81   Inexact Rounded Subnormal Underflow
! mulx896 multiply  1.23456E-41  1.234E-40  ->  1.52E-81   Inexact Rounded Subnormal Underflow
! 
! -- Null tests
! mulx900 multiply 10  # -> NaN Invalid_operation
! mulx901 multiply  # 10 -> NaN Invalid_operation
! 

Index: normalize.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/normalize.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** normalize.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- normalize.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,225 ****
! ------------------------------------------------------------------------
! -- normalize.decTest -- remove trailing zeros                         --
! -- Copyright (c) IBM Corporation, 2003.  All rights reserved.         --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.35
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minexponent: -999
! 
! nrmx001 normalize '1'      -> '1'
! nrmx002 normalize '-1'     -> '-1'
! nrmx003 normalize '1.00'   -> '1'
! nrmx004 normalize '-1.00'  -> '-1'
! nrmx005 normalize '0'      -> '0'
! nrmx006 normalize '0.00'   -> '0'
! nrmx007 normalize '00.0'   -> '0'
! nrmx008 normalize '00.00'  -> '0'
! nrmx009 normalize '00'     -> '0'
! nrmx010 normalize '0E+1'   -> '0'
! nrmx011 normalize '0E+5'   -> '0'
! 
! nrmx012 normalize '-2'     -> '-2'
! nrmx013 normalize '2'      -> '2'
! nrmx014 normalize '-2.00'  -> '-2'
! nrmx015 normalize '2.00'   -> '2'
! nrmx016 normalize '-0'     -> '-0'
! nrmx017 normalize '-0.00'  -> '-0'
! nrmx018 normalize '-00.0'  -> '-0'
! nrmx019 normalize '-00.00' -> '-0'
! nrmx020 normalize '-00'    -> '-0'
! nrmx021 normalize '-0E+5'   -> '-0'
! nrmx022 normalize '-0E+1'  -> '-0'
! 
! nrmx030 normalize '+0.1'            -> '0.1'
! nrmx031 normalize '-0.1'            -> '-0.1'
! nrmx032 normalize '+0.01'           -> '0.01'
! nrmx033 normalize '-0.01'           -> '-0.01'
! nrmx034 normalize '+0.001'          -> '0.001'
! nrmx035 normalize '-0.001'          -> '-0.001'
! nrmx036 normalize '+0.000001'       -> '0.000001'
! nrmx037 normalize '-0.000001'       -> '-0.000001'
! nrmx038 normalize '+0.000000000001' -> '1E-12'
! nrmx039 normalize '-0.000000000001' -> '-1E-12'
! 
! nrmx041 normalize 1.1        -> 1.1
! nrmx042 normalize 1.10       -> 1.1
! nrmx043 normalize 1.100      -> 1.1
! nrmx044 normalize 1.110      -> 1.11
! nrmx045 normalize -1.1       -> -1.1
! nrmx046 normalize -1.10      -> -1.1
! nrmx047 normalize -1.100     -> -1.1
! nrmx048 normalize -1.110     -> -1.11
! nrmx049 normalize 9.9        -> 9.9
! nrmx050 normalize 9.90       -> 9.9
! nrmx051 normalize 9.900      -> 9.9
! nrmx052 normalize 9.990      -> 9.99
! nrmx053 normalize -9.9       -> -9.9
! nrmx054 normalize -9.90      -> -9.9
! nrmx055 normalize -9.900     -> -9.9
! nrmx056 normalize -9.990     -> -9.99
! 
! -- some trailing fractional zeros with zeros in units
! nrmx060 normalize  10.0        -> 1E+1
! nrmx061 normalize  10.00       -> 1E+1
! nrmx062 normalize  100.0       -> 1E+2
! nrmx063 normalize  100.00      -> 1E+2
! nrmx064 normalize  1.1000E+3   -> 1.1E+3
! nrmx065 normalize  1.10000E+3  -> 1.1E+3
! nrmx066 normalize -10.0        -> -1E+1
! nrmx067 normalize -10.00       -> -1E+1
! nrmx068 normalize -100.0       -> -1E+2
! nrmx069 normalize -100.00      -> -1E+2
! nrmx070 normalize -1.1000E+3   -> -1.1E+3
! nrmx071 normalize -1.10000E+3  -> -1.1E+3
! 
! -- some insignificant trailing zeros with positive exponent
! nrmx080 normalize  10E+1       -> 1E+2
! nrmx081 normalize  100E+1      -> 1E+3
! nrmx082 normalize  1.0E+2      -> 1E+2
! nrmx083 normalize  1.0E+3      -> 1E+3
! nrmx084 normalize  1.1E+3      -> 1.1E+3
! nrmx085 normalize  1.00E+3     -> 1E+3
! nrmx086 normalize  1.10E+3     -> 1.1E+3
! nrmx087 normalize -10E+1       -> -1E+2
! nrmx088 normalize -100E+1      -> -1E+3
! nrmx089 normalize -1.0E+2      -> -1E+2
! nrmx090 normalize -1.0E+3      -> -1E+3
! nrmx091 normalize -1.1E+3      -> -1.1E+3
! nrmx092 normalize -1.00E+3     -> -1E+3
! nrmx093 normalize -1.10E+3     -> -1.1E+3
! 
! -- some significant trailing zeros, were we to be trimming
! nrmx100 normalize  11          -> 11
! nrmx101 normalize  10          -> 1E+1
! nrmx102 normalize  10.         -> 1E+1
! nrmx103 normalize  1.1E+1      -> 11
! nrmx104 normalize  1.0E+1      -> 1E+1
! nrmx105 normalize  1.10E+2     -> 1.1E+2
! nrmx106 normalize  1.00E+2     -> 1E+2
! nrmx107 normalize  1.100E+3    -> 1.1E+3
! nrmx108 normalize  1.000E+3    -> 1E+3
! nrmx109 normalize  1.000000E+6 -> 1E+6
! nrmx110 normalize -11          -> -11
! nrmx111 normalize -10          -> -1E+1
! nrmx112 normalize -10.         -> -1E+1
! nrmx113 normalize -1.1E+1      -> -11
! nrmx114 normalize -1.0E+1      -> -1E+1
! nrmx115 normalize -1.10E+2     -> -1.1E+2
! nrmx116 normalize -1.00E+2     -> -1E+2
! nrmx117 normalize -1.100E+3    -> -1.1E+3
! nrmx118 normalize -1.000E+3    -> -1E+3
! nrmx119 normalize -1.00000E+5  -> -1E+5
! nrmx120 normalize -1.000000E+6 -> -1E+6
! nrmx121 normalize -10.00000E+6 -> -1E+7
! nrmx122 normalize -100.0000E+6 -> -1E+8
! nrmx123 normalize -1000.000E+6 -> -1E+9
! nrmx124 normalize -10000.00E+6 -> -1E+10
! nrmx125 normalize -100000.0E+6 -> -1E+11
! nrmx126 normalize -1000000.E+6 -> -1E+12
! 
! -- examples from decArith
! nrmx140 normalize '2.1'     ->  '2.1'
! nrmx141 normalize '-2.0'    ->  '-2'
! nrmx142 normalize '1.200'   ->  '1.2'
! nrmx143 normalize '-120'    ->  '-1.2E+2'
! nrmx144 normalize '120.00'  ->  '1.2E+2'
! nrmx145 normalize '0.00'    ->  '0'
! 
! -- overflow tests
! maxexponent: 999999999
! minexponent: -999999999
! precision: 3
! nrmx160 normalize 9.999E+999999999  ->  Infinity Inexact Overflow Rounded
! nrmx161 normalize -9.999E+999999999 -> -Infinity Inexact Overflow Rounded
! 
! -- subnormals and underflow
! precision: 3
! maxexponent: 999
! minexponent: -999
! nrmx210 normalize  1.00E-999        ->   1E-999
! nrmx211 normalize  0.1E-999         ->   1E-1000   Subnormal
! nrmx212 normalize  0.10E-999        ->   1E-1000   Subnormal
! nrmx213 normalize  0.100E-999       ->   1E-1000   Subnormal Rounded
! nrmx214 normalize  0.01E-999        ->   1E-1001   Subnormal
! -- next is rounded to Emin
! nrmx215 normalize  0.999E-999       ->   1E-999    Inexact Rounded Subnormal Underflow
! nrmx216 normalize  0.099E-999       ->   1E-1000   Inexact Rounded Subnormal Underflow
! nrmx217 normalize  0.009E-999       ->   1E-1001   Inexact Rounded Subnormal Underflow
! nrmx218 normalize  0.001E-999       ->   0         Inexact Rounded Subnormal Underflow
! nrmx219 normalize  0.0009E-999      ->   0         Inexact Rounded Subnormal Underflow
! nrmx220 normalize  0.0001E-999      ->   0         Inexact Rounded Subnormal Underflow
! 
! nrmx230 normalize -1.00E-999        ->  -1E-999
! nrmx231 normalize -0.1E-999         ->  -1E-1000   Subnormal
! nrmx232 normalize -0.10E-999        ->  -1E-1000   Subnormal
! nrmx233 normalize -0.100E-999       ->  -1E-1000   Subnormal Rounded
! nrmx234 normalize -0.01E-999        ->  -1E-1001   Subnormal
! -- next is rounded to Emin
! nrmx235 normalize -0.999E-999       ->  -1E-999    Inexact Rounded Subnormal Underflow
! nrmx236 normalize -0.099E-999       ->  -1E-1000   Inexact Rounded Subnormal Underflow
! nrmx237 normalize -0.009E-999       ->  -1E-1001   Inexact Rounded Subnormal Underflow
! nrmx238 normalize -0.001E-999       ->  -0         Inexact Rounded Subnormal Underflow
! nrmx239 normalize -0.0009E-999      ->  -0         Inexact Rounded Subnormal Underflow
! nrmx240 normalize -0.0001E-999      ->  -0         Inexact Rounded Subnormal Underflow
! 
! -- more reshaping
! precision: 9
! nrmx260 normalize '56260E-10'   -> '0.000005626'
! nrmx261 normalize '56260E-5'    -> '0.5626'
! nrmx262 normalize '56260E-2'    -> '562.6'
! nrmx263 normalize '56260E-1'    -> '5626'
! nrmx265 normalize '56260E-0'    -> '5.626E+4'
! nrmx266 normalize '56260E+0'    -> '5.626E+4'
! nrmx267 normalize '56260E+1'    -> '5.626E+5'
! nrmx268 normalize '56260E+2'    -> '5.626E+6'
! nrmx269 normalize '56260E+3'    -> '5.626E+7'
! nrmx270 normalize '56260E+4'    -> '5.626E+8'
! nrmx271 normalize '56260E+5'    -> '5.626E+9'
! nrmx272 normalize '56260E+6'    -> '5.626E+10'
! nrmx280 normalize '-56260E-10'  -> '-0.000005626'
! nrmx281 normalize '-56260E-5'   -> '-0.5626'
! nrmx282 normalize '-56260E-2'   -> '-562.6'
! nrmx283 normalize '-56260E-1'   -> '-5626'
! nrmx285 normalize '-56260E-0'   -> '-5.626E+4'
! nrmx286 normalize '-56260E+0'   -> '-5.626E+4'
! nrmx287 normalize '-56260E+1'   -> '-5.626E+5'
! nrmx288 normalize '-56260E+2'   -> '-5.626E+6'
! nrmx289 normalize '-56260E+3'   -> '-5.626E+7'
! nrmx290 normalize '-56260E+4'   -> '-5.626E+8'
! nrmx291 normalize '-56260E+5'   -> '-5.626E+9'
! nrmx292 normalize '-56260E+6'   -> '-5.626E+10'
! 
! 
! -- specials
! nrmx820 normalize 'Inf'    -> 'Infinity'
! nrmx821 normalize '-Inf'   -> '-Infinity'
! nrmx822 normalize   NaN    ->  NaN
! nrmx823 normalize  sNaN    ->  NaN    Invalid_operation
! nrmx824 normalize   NaN101 ->  NaN101
! nrmx825 normalize  sNaN010 ->  NaN10  Invalid_operation
! nrmx827 normalize  -NaN    -> -NaN
! nrmx828 normalize -sNaN    -> -NaN    Invalid_operation
! nrmx829 normalize  -NaN101 -> -NaN101
! nrmx830 normalize -sNaN010 -> -NaN10  Invalid_operation
! 
! -- Null test
! nrmx900 normalize  # -> NaN Invalid_operation
--- 1,225 ----
! ------------------------------------------------------------------------
! -- normalize.decTest -- remove trailing zeros                         --
! -- Copyright (c) IBM Corporation, 2003.  All rights reserved.         --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.38
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minexponent: -999
! 
! nrmx001 normalize '1'      -> '1'
! nrmx002 normalize '-1'     -> '-1'
! nrmx003 normalize '1.00'   -> '1'
! nrmx004 normalize '-1.00'  -> '-1'
! nrmx005 normalize '0'      -> '0'
! nrmx006 normalize '0.00'   -> '0'
! nrmx007 normalize '00.0'   -> '0'
! nrmx008 normalize '00.00'  -> '0'
! nrmx009 normalize '00'     -> '0'
! nrmx010 normalize '0E+1'   -> '0'
! nrmx011 normalize '0E+5'   -> '0'
! 
! nrmx012 normalize '-2'     -> '-2'
! nrmx013 normalize '2'      -> '2'
! nrmx014 normalize '-2.00'  -> '-2'
! nrmx015 normalize '2.00'   -> '2'
! nrmx016 normalize '-0'     -> '-0'
! nrmx017 normalize '-0.00'  -> '-0'
! nrmx018 normalize '-00.0'  -> '-0'
! nrmx019 normalize '-00.00' -> '-0'
! nrmx020 normalize '-00'    -> '-0'
! nrmx021 normalize '-0E+5'   -> '-0'
! nrmx022 normalize '-0E+1'  -> '-0'
! 
! nrmx030 normalize '+0.1'            -> '0.1'
! nrmx031 normalize '-0.1'            -> '-0.1'
! nrmx032 normalize '+0.01'           -> '0.01'
! nrmx033 normalize '-0.01'           -> '-0.01'
! nrmx034 normalize '+0.001'          -> '0.001'
! nrmx035 normalize '-0.001'          -> '-0.001'
! nrmx036 normalize '+0.000001'       -> '0.000001'
! nrmx037 normalize '-0.000001'       -> '-0.000001'
! nrmx038 normalize '+0.000000000001' -> '1E-12'
! nrmx039 normalize '-0.000000000001' -> '-1E-12'
! 
! nrmx041 normalize 1.1        -> 1.1
! nrmx042 normalize 1.10       -> 1.1
! nrmx043 normalize 1.100      -> 1.1
! nrmx044 normalize 1.110      -> 1.11
! nrmx045 normalize -1.1       -> -1.1
! nrmx046 normalize -1.10      -> -1.1
! nrmx047 normalize -1.100     -> -1.1
! nrmx048 normalize -1.110     -> -1.11
! nrmx049 normalize 9.9        -> 9.9
! nrmx050 normalize 9.90       -> 9.9
! nrmx051 normalize 9.900      -> 9.9
! nrmx052 normalize 9.990      -> 9.99
! nrmx053 normalize -9.9       -> -9.9
! nrmx054 normalize -9.90      -> -9.9
! nrmx055 normalize -9.900     -> -9.9
! nrmx056 normalize -9.990     -> -9.99
! 
! -- some trailing fractional zeros with zeros in units
! nrmx060 normalize  10.0        -> 1E+1
! nrmx061 normalize  10.00       -> 1E+1
! nrmx062 normalize  100.0       -> 1E+2
! nrmx063 normalize  100.00      -> 1E+2
! nrmx064 normalize  1.1000E+3   -> 1.1E+3
! nrmx065 normalize  1.10000E+3  -> 1.1E+3
! nrmx066 normalize -10.0        -> -1E+1
! nrmx067 normalize -10.00       -> -1E+1
! nrmx068 normalize -100.0       -> -1E+2
! nrmx069 normalize -100.00      -> -1E+2
! nrmx070 normalize -1.1000E+3   -> -1.1E+3
! nrmx071 normalize -1.10000E+3  -> -1.1E+3
! 
! -- some insignificant trailing zeros with positive exponent
! nrmx080 normalize  10E+1       -> 1E+2
! nrmx081 normalize  100E+1      -> 1E+3
! nrmx082 normalize  1.0E+2      -> 1E+2
! nrmx083 normalize  1.0E+3      -> 1E+3
! nrmx084 normalize  1.1E+3      -> 1.1E+3
! nrmx085 normalize  1.00E+3     -> 1E+3
! nrmx086 normalize  1.10E+3     -> 1.1E+3
! nrmx087 normalize -10E+1       -> -1E+2
! nrmx088 normalize -100E+1      -> -1E+3
! nrmx089 normalize -1.0E+2      -> -1E+2
! nrmx090 normalize -1.0E+3      -> -1E+3
! nrmx091 normalize -1.1E+3      -> -1.1E+3
! nrmx092 normalize -1.00E+3     -> -1E+3
! nrmx093 normalize -1.10E+3     -> -1.1E+3
! 
! -- some significant trailing zeros, were we to be trimming
! nrmx100 normalize  11          -> 11
! nrmx101 normalize  10          -> 1E+1
! nrmx102 normalize  10.         -> 1E+1
! nrmx103 normalize  1.1E+1      -> 11
! nrmx104 normalize  1.0E+1      -> 1E+1
! nrmx105 normalize  1.10E+2     -> 1.1E+2
! nrmx106 normalize  1.00E+2     -> 1E+2
! nrmx107 normalize  1.100E+3    -> 1.1E+3
! nrmx108 normalize  1.000E+3    -> 1E+3
! nrmx109 normalize  1.000000E+6 -> 1E+6
! nrmx110 normalize -11          -> -11
! nrmx111 normalize -10          -> -1E+1
! nrmx112 normalize -10.         -> -1E+1
! nrmx113 normalize -1.1E+1      -> -11
! nrmx114 normalize -1.0E+1      -> -1E+1
! nrmx115 normalize -1.10E+2     -> -1.1E+2
! nrmx116 normalize -1.00E+2     -> -1E+2
! nrmx117 normalize -1.100E+3    -> -1.1E+3
! nrmx118 normalize -1.000E+3    -> -1E+3
! nrmx119 normalize -1.00000E+5  -> -1E+5
! nrmx120 normalize -1.000000E+6 -> -1E+6
! nrmx121 normalize -10.00000E+6 -> -1E+7
! nrmx122 normalize -100.0000E+6 -> -1E+8
! nrmx123 normalize -1000.000E+6 -> -1E+9
! nrmx124 normalize -10000.00E+6 -> -1E+10
! nrmx125 normalize -100000.0E+6 -> -1E+11
! nrmx126 normalize -1000000.E+6 -> -1E+12
! 
! -- examples from decArith
! nrmx140 normalize '2.1'     ->  '2.1'
! nrmx141 normalize '-2.0'    ->  '-2'
! nrmx142 normalize '1.200'   ->  '1.2'
! nrmx143 normalize '-120'    ->  '-1.2E+2'
! nrmx144 normalize '120.00'  ->  '1.2E+2'
! nrmx145 normalize '0.00'    ->  '0'
! 
! -- overflow tests
! maxexponent: 999999999
! minexponent: -999999999
! precision: 3
! nrmx160 normalize 9.999E+999999999  ->  Infinity Inexact Overflow Rounded
! nrmx161 normalize -9.999E+999999999 -> -Infinity Inexact Overflow Rounded
! 
! -- subnormals and underflow
! precision: 3
! maxexponent: 999
! minexponent: -999
! nrmx210 normalize  1.00E-999        ->   1E-999
! nrmx211 normalize  0.1E-999         ->   1E-1000   Subnormal
! nrmx212 normalize  0.10E-999        ->   1E-1000   Subnormal
! nrmx213 normalize  0.100E-999       ->   1E-1000   Subnormal Rounded
! nrmx214 normalize  0.01E-999        ->   1E-1001   Subnormal
! -- next is rounded to Emin
! nrmx215 normalize  0.999E-999       ->   1E-999    Inexact Rounded Subnormal Underflow
! nrmx216 normalize  0.099E-999       ->   1E-1000   Inexact Rounded Subnormal Underflow
! nrmx217 normalize  0.009E-999       ->   1E-1001   Inexact Rounded Subnormal Underflow
! nrmx218 normalize  0.001E-999       ->   0         Inexact Rounded Subnormal Underflow
! nrmx219 normalize  0.0009E-999      ->   0         Inexact Rounded Subnormal Underflow
! nrmx220 normalize  0.0001E-999      ->   0         Inexact Rounded Subnormal Underflow
! 
! nrmx230 normalize -1.00E-999        ->  -1E-999
! nrmx231 normalize -0.1E-999         ->  -1E-1000   Subnormal
! nrmx232 normalize -0.10E-999        ->  -1E-1000   Subnormal
! nrmx233 normalize -0.100E-999       ->  -1E-1000   Subnormal Rounded
! nrmx234 normalize -0.01E-999        ->  -1E-1001   Subnormal
! -- next is rounded to Emin
! nrmx235 normalize -0.999E-999       ->  -1E-999    Inexact Rounded Subnormal Underflow
! nrmx236 normalize -0.099E-999       ->  -1E-1000   Inexact Rounded Subnormal Underflow
! nrmx237 normalize -0.009E-999       ->  -1E-1001   Inexact Rounded Subnormal Underflow
! nrmx238 normalize -0.001E-999       ->  -0         Inexact Rounded Subnormal Underflow
! nrmx239 normalize -0.0009E-999      ->  -0         Inexact Rounded Subnormal Underflow
! nrmx240 normalize -0.0001E-999      ->  -0         Inexact Rounded Subnormal Underflow
! 
! -- more reshaping
! precision: 9
! nrmx260 normalize '56260E-10'   -> '0.000005626'
! nrmx261 normalize '56260E-5'    -> '0.5626'
! nrmx262 normalize '56260E-2'    -> '562.6'
! nrmx263 normalize '56260E-1'    -> '5626'
! nrmx265 normalize '56260E-0'    -> '5.626E+4'
! nrmx266 normalize '56260E+0'    -> '5.626E+4'
! nrmx267 normalize '56260E+1'    -> '5.626E+5'
! nrmx268 normalize '56260E+2'    -> '5.626E+6'
! nrmx269 normalize '56260E+3'    -> '5.626E+7'
! nrmx270 normalize '56260E+4'    -> '5.626E+8'
! nrmx271 normalize '56260E+5'    -> '5.626E+9'
! nrmx272 normalize '56260E+6'    -> '5.626E+10'
! nrmx280 normalize '-56260E-10'  -> '-0.000005626'
! nrmx281 normalize '-56260E-5'   -> '-0.5626'
! nrmx282 normalize '-56260E-2'   -> '-562.6'
! nrmx283 normalize '-56260E-1'   -> '-5626'
! nrmx285 normalize '-56260E-0'   -> '-5.626E+4'
! nrmx286 normalize '-56260E+0'   -> '-5.626E+4'
! nrmx287 normalize '-56260E+1'   -> '-5.626E+5'
! nrmx288 normalize '-56260E+2'   -> '-5.626E+6'
! nrmx289 normalize '-56260E+3'   -> '-5.626E+7'
! nrmx290 normalize '-56260E+4'   -> '-5.626E+8'
! nrmx291 normalize '-56260E+5'   -> '-5.626E+9'
! nrmx292 normalize '-56260E+6'   -> '-5.626E+10'
! 
! 
! -- specials
! nrmx820 normalize 'Inf'    -> 'Infinity'
! nrmx821 normalize '-Inf'   -> '-Infinity'
! nrmx822 normalize   NaN    ->  NaN
! nrmx823 normalize  sNaN    ->  NaN    Invalid_operation
! nrmx824 normalize   NaN101 ->  NaN101
! nrmx825 normalize  sNaN010 ->  NaN10  Invalid_operation
! nrmx827 normalize  -NaN    -> -NaN
! nrmx828 normalize -sNaN    -> -NaN    Invalid_operation
! nrmx829 normalize  -NaN101 -> -NaN101
! nrmx830 normalize -sNaN010 -> -NaN10  Invalid_operation
! 
! -- Null test
! nrmx900 normalize  # -> NaN Invalid_operation

Index: plus.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/plus.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** plus.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- plus.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,181 ****
! ------------------------------------------------------------------------
! -- plus.decTest -- decimal monadic addition                           --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.35
! 
! -- This set of tests primarily tests the existence of the operator.
! -- Addition and rounding, and most overflows, are tested elsewhere.
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minexponent: -999
! 
! plux001 plus '1'      -> '1'
! plux002 plus '-1'     -> '-1'
! plux003 plus '1.00'   -> '1.00'
! plux004 plus '-1.00'  -> '-1.00'
! plux005 plus '0'      -> '0'
! plux006 plus '0.00'   -> '0.00'
! plux007 plus '00.0'   -> '0.0'
! plux008 plus '00.00'  -> '0.00'
! plux009 plus '00'     -> '0'
! 
! plux010 plus '-2'     -> '-2'
! plux011 plus '2'      -> '2'
! plux012 plus '-2.00'  -> '-2.00'
! plux013 plus '2.00'   -> '2.00'
! plux014 plus '-0'     -> '0'
! plux015 plus '-0.00'  -> '0.00'
! plux016 plus '-00.0'  -> '0.0'
! plux017 plus '-00.00' -> '0.00'
! plux018 plus '-00'    -> '0'
! 
! plux020 plus '-2000000' -> '-2000000'
! plux021 plus '2000000'  -> '2000000'
! precision: 7
! plux022 plus '-2000000' -> '-2000000'
! plux023 plus '2000000'  -> '2000000'
! precision: 6
! plux024 plus '-2000000' -> '-2.00000E+6' Rounded
! plux025 plus '2000000'  -> '2.00000E+6' Rounded
! precision: 3
! plux026 plus '-2000000' -> '-2.00E+6' Rounded
! plux027 plus '2000000'  -> '2.00E+6' Rounded
! 
! -- more fixed, potential LHS swaps if done by add 0
! precision: 9
! plux060 plus '56267E-10'   -> '0.0000056267'
! plux061 plus '56267E-5'    -> '0.56267'
! plux062 plus '56267E-2'    -> '562.67'
! plux063 plus '56267E-1'    -> '5626.7'
! plux065 plus '56267E-0'    -> '56267'
! plux066 plus '56267E+0'    -> '56267'
! plux067 plus '56267E+1'    -> '5.6267E+5'
! plux068 plus '56267E+2'    -> '5.6267E+6'
! plux069 plus '56267E+3'    -> '5.6267E+7'
! plux070 plus '56267E+4'    -> '5.6267E+8'
! plux071 plus '56267E+5'    -> '5.6267E+9'
! plux072 plus '56267E+6'    -> '5.6267E+10'
! plux080 plus '-56267E-10'  -> '-0.0000056267'
! plux081 plus '-56267E-5'   -> '-0.56267'
! plux082 plus '-56267E-2'   -> '-562.67'
! plux083 plus '-56267E-1'   -> '-5626.7'
! plux085 plus '-56267E-0'   -> '-56267'
! plux086 plus '-56267E+0'   -> '-56267'
! plux087 plus '-56267E+1'   -> '-5.6267E+5'
! plux088 plus '-56267E+2'   -> '-5.6267E+6'
! plux089 plus '-56267E+3'   -> '-5.6267E+7'
! plux090 plus '-56267E+4'   -> '-5.6267E+8'
! plux091 plus '-56267E+5'   -> '-5.6267E+9'
! plux092 plus '-56267E+6'   -> '-5.6267E+10'
! 
! -- "lhs" zeros in plus and minus have exponent = operand
! plux120 plus '-0E3'   -> '0E+3'
! plux121 plus '-0E2'   -> '0E+2'
! plux122 plus '-0E1'   -> '0E+1'
! plux123 plus '-0E0'   -> '0'
! plux124 plus '+0E0'   -> '0'
! plux125 plus '+0E1'   -> '0E+1'
! plux126 plus '+0E2'   -> '0E+2'
! plux127 plus '+0E3'   -> '0E+3'
! 
! plux130 plus '-5E3'   -> '-5E+3'
! plux131 plus '-5E8'   -> '-5E+8'
! plux132 plus '-5E13'  -> '-5E+13'
! plux133 plus '-5E18'  -> '-5E+18'
! plux134 plus '+5E3'   -> '5E+3'
! plux135 plus '+5E8'   -> '5E+8'
! plux136 plus '+5E13'  -> '5E+13'
! plux137 plus '+5E18'  -> '5E+18'
! 
! -- specials
! plux150 plus 'Inf'    -> 'Infinity'
! plux151 plus '-Inf'   -> '-Infinity'
! plux152 plus   NaN    ->  NaN
! plux153 plus  sNaN    ->  NaN   Invalid_operation
! plux154 plus   NaN77  ->  NaN77
! plux155 plus  sNaN88  ->  NaN88 Invalid_operation
! plux156 plus  -NaN    -> -NaN
! plux157 plus -sNaN    -> -NaN   Invalid_operation
! plux158 plus  -NaN77  -> -NaN77
! plux159 plus -sNaN88  -> -NaN88 Invalid_operation
! 
! -- overflow tests
! maxexponent: 999999999
! minexponent: -999999999
! precision: 3
! plux160 plus 9.999E+999999999  ->  Infinity Inexact Overflow Rounded
! plux161 plus -9.999E+999999999 -> -Infinity Inexact Overflow Rounded
! 
! -- subnormals and underflow
! precision: 3
! maxexponent: 999
! minexponent: -999
! plux210 plus  1.00E-999        ->   1.00E-999
! plux211 plus  0.1E-999         ->   1E-1000   Subnormal
! plux212 plus  0.10E-999        ->   1.0E-1000 Subnormal
! plux213 plus  0.100E-999       ->   1.0E-1000 Subnormal Rounded
! plux214 plus  0.01E-999        ->   1E-1001   Subnormal
! -- next is rounded to Emin
! plux215 plus  0.999E-999       ->   1.00E-999 Inexact Rounded Subnormal Underflow
! plux216 plus  0.099E-999       ->   1.0E-1000 Inexact Rounded Subnormal Underflow
! plux217 plus  0.009E-999       ->   1E-1001   Inexact Rounded Subnormal Underflow
! plux218 plus  0.001E-999       ->   0E-1001   Inexact Rounded Subnormal Underflow
! plux219 plus  0.0009E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! plux220 plus  0.0001E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! 
! plux230 plus -1.00E-999        ->  -1.00E-999
! plux231 plus -0.1E-999         ->  -1E-1000   Subnormal
! plux232 plus -0.10E-999        ->  -1.0E-1000 Subnormal
! plux233 plus -0.100E-999       ->  -1.0E-1000 Subnormal Rounded
! plux234 plus -0.01E-999        ->  -1E-1001   Subnormal
! -- next is rounded to Emin
! plux235 plus -0.999E-999       ->  -1.00E-999 Inexact Rounded Subnormal Underflow
! plux236 plus -0.099E-999       ->  -1.0E-1000 Inexact Rounded Subnormal Underflow
! plux237 plus -0.009E-999       ->  -1E-1001   Inexact Rounded Subnormal Underflow
! plux238 plus -0.001E-999       ->  -0E-1001   Inexact Rounded Subnormal Underflow
! plux239 plus -0.0009E-999      ->  -0E-1001   Inexact Rounded Subnormal Underflow
! plux240 plus -0.0001E-999      ->  -0E-1001   Inexact Rounded Subnormal Underflow
! 
! -- long operand checks
! maxexponent: 999
! minexponent: -999
! precision: 9
! plux301 plus 12345678000  -> 1.23456780E+10 Rounded
! plux302 plus 1234567800   -> 1.23456780E+9 Rounded
! plux303 plus 1234567890   -> 1.23456789E+9 Rounded
! plux304 plus 1234567891   -> 1.23456789E+9 Inexact Rounded
! plux305 plus 12345678901  -> 1.23456789E+10 Inexact Rounded
! plux306 plus 1234567896   -> 1.23456790E+9 Inexact Rounded
! 
! -- still checking
! precision: 15
! plux321 plus 12345678000  -> 12345678000
! plux322 plus 1234567800   -> 1234567800
! plux323 plus 1234567890   -> 1234567890
! plux324 plus 1234567891   -> 1234567891
! plux325 plus 12345678901  -> 12345678901
! plux326 plus 1234567896   -> 1234567896
! precision: 9
! 
! -- Null tests
! plu900 plus  # -> NaN Invalid_operation
! 
--- 1,181 ----
! ------------------------------------------------------------------------
! -- plus.decTest -- decimal monadic addition                           --
! -- Copyright (c) IBM Corporation, 1981, 2004.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.38
! 
! -- This set of tests primarily tests the existence of the operator.
! -- Addition and rounding, and most overflows, are tested elsewhere.
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 384
! minexponent: -383
! 
! plux001 plus '1'      -> '1'
! plux002 plus '-1'     -> '-1'
! plux003 plus '1.00'   -> '1.00'
! plux004 plus '-1.00'  -> '-1.00'
! plux005 plus '0'      -> '0'
! plux006 plus '0.00'   -> '0.00'
! plux007 plus '00.0'   -> '0.0'
! plux008 plus '00.00'  -> '0.00'
! plux009 plus '00'     -> '0'
! 
! plux010 plus '-2'     -> '-2'
! plux011 plus '2'      -> '2'
! plux012 plus '-2.00'  -> '-2.00'
! plux013 plus '2.00'   -> '2.00'
! plux014 plus '-0'     -> '0'
! plux015 plus '-0.00'  -> '0.00'
! plux016 plus '-00.0'  -> '0.0'
! plux017 plus '-00.00' -> '0.00'
! plux018 plus '-00'    -> '0'
! 
! plux020 plus '-2000000' -> '-2000000'
! plux021 plus '2000000'  -> '2000000'
! precision: 7
! plux022 plus '-2000000' -> '-2000000'
! plux023 plus '2000000'  -> '2000000'
! precision: 6
! plux024 plus '-2000000' -> '-2.00000E+6' Rounded
! plux025 plus '2000000'  -> '2.00000E+6' Rounded
! precision: 3
! plux026 plus '-2000000' -> '-2.00E+6' Rounded
! plux027 plus '2000000'  -> '2.00E+6' Rounded
! 
! -- more fixed, potential LHS swaps if done by add 0
! precision: 9
! plux060 plus '56267E-10'   -> '0.0000056267'
! plux061 plus '56267E-5'    -> '0.56267'
! plux062 plus '56267E-2'    -> '562.67'
! plux063 plus '56267E-1'    -> '5626.7'
! plux065 plus '56267E-0'    -> '56267'
! plux066 plus '56267E+0'    -> '56267'
! plux067 plus '56267E+1'    -> '5.6267E+5'
! plux068 plus '56267E+2'    -> '5.6267E+6'
! plux069 plus '56267E+3'    -> '5.6267E+7'
! plux070 plus '56267E+4'    -> '5.6267E+8'
! plux071 plus '56267E+5'    -> '5.6267E+9'
! plux072 plus '56267E+6'    -> '5.6267E+10'
! plux080 plus '-56267E-10'  -> '-0.0000056267'
! plux081 plus '-56267E-5'   -> '-0.56267'
! plux082 plus '-56267E-2'   -> '-562.67'
! plux083 plus '-56267E-1'   -> '-5626.7'
! plux085 plus '-56267E-0'   -> '-56267'
! plux086 plus '-56267E+0'   -> '-56267'
! plux087 plus '-56267E+1'   -> '-5.6267E+5'
! plux088 plus '-56267E+2'   -> '-5.6267E+6'
! plux089 plus '-56267E+3'   -> '-5.6267E+7'
! plux090 plus '-56267E+4'   -> '-5.6267E+8'
! plux091 plus '-56267E+5'   -> '-5.6267E+9'
! plux092 plus '-56267E+6'   -> '-5.6267E+10'
! 
! -- "lhs" zeros in plus and minus have exponent = operand
! plux120 plus '-0E3'   -> '0E+3'
! plux121 plus '-0E2'   -> '0E+2'
! plux122 plus '-0E1'   -> '0E+1'
! plux123 plus '-0E0'   -> '0'
! plux124 plus '+0E0'   -> '0'
! plux125 plus '+0E1'   -> '0E+1'
! plux126 plus '+0E2'   -> '0E+2'
! plux127 plus '+0E3'   -> '0E+3'
! 
! plux130 plus '-5E3'   -> '-5E+3'
! plux131 plus '-5E8'   -> '-5E+8'
! plux132 plus '-5E13'  -> '-5E+13'
! plux133 plus '-5E18'  -> '-5E+18'
! plux134 plus '+5E3'   -> '5E+3'
! plux135 plus '+5E8'   -> '5E+8'
! plux136 plus '+5E13'  -> '5E+13'
! plux137 plus '+5E18'  -> '5E+18'
! 
! -- specials
! plux150 plus 'Inf'    -> 'Infinity'
! plux151 plus '-Inf'   -> '-Infinity'
! plux152 plus   NaN    ->  NaN
! plux153 plus  sNaN    ->  NaN   Invalid_operation
! plux154 plus   NaN77  ->  NaN77
! plux155 plus  sNaN88  ->  NaN88 Invalid_operation
! plux156 plus  -NaN    -> -NaN
! plux157 plus -sNaN    -> -NaN   Invalid_operation
! plux158 plus  -NaN77  -> -NaN77
! plux159 plus -sNaN88  -> -NaN88 Invalid_operation
! 
! -- overflow tests
! maxexponent: 999999999
! minexponent: -999999999
! precision: 3
! plux160 plus 9.999E+999999999  ->  Infinity Inexact Overflow Rounded
! plux161 plus -9.999E+999999999 -> -Infinity Inexact Overflow Rounded
! 
! -- subnormals and underflow
! precision: 3
! maxexponent: 999
! minexponent: -999
! plux210 plus  1.00E-999        ->   1.00E-999
! plux211 plus  0.1E-999         ->   1E-1000   Subnormal
! plux212 plus  0.10E-999        ->   1.0E-1000 Subnormal
! plux213 plus  0.100E-999       ->   1.0E-1000 Subnormal Rounded
! plux214 plus  0.01E-999        ->   1E-1001   Subnormal
! -- next is rounded to Emin
! plux215 plus  0.999E-999       ->   1.00E-999 Inexact Rounded Subnormal Underflow
! plux216 plus  0.099E-999       ->   1.0E-1000 Inexact Rounded Subnormal Underflow
! plux217 plus  0.009E-999       ->   1E-1001   Inexact Rounded Subnormal Underflow
! plux218 plus  0.001E-999       ->   0E-1001   Inexact Rounded Subnormal Underflow
! plux219 plus  0.0009E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! plux220 plus  0.0001E-999      ->   0E-1001   Inexact Rounded Subnormal Underflow
! 
! plux230 plus -1.00E-999        ->  -1.00E-999
! plux231 plus -0.1E-999         ->  -1E-1000   Subnormal
! plux232 plus -0.10E-999        ->  -1.0E-1000 Subnormal
! plux233 plus -0.100E-999       ->  -1.0E-1000 Subnormal Rounded
! plux234 plus -0.01E-999        ->  -1E-1001   Subnormal
! -- next is rounded to Emin
! plux235 plus -0.999E-999       ->  -1.00E-999 Inexact Rounded Subnormal Underflow
! plux236 plus -0.099E-999       ->  -1.0E-1000 Inexact Rounded Subnormal Underflow
! plux237 plus -0.009E-999       ->  -1E-1001   Inexact Rounded Subnormal Underflow
! plux238 plus -0.001E-999       ->  -0E-1001   Inexact Rounded Subnormal Underflow
! plux239 plus -0.0009E-999      ->  -0E-1001   Inexact Rounded Subnormal Underflow
! plux240 plus -0.0001E-999      ->  -0E-1001   Inexact Rounded Subnormal Underflow
! 
! -- long operand checks
! maxexponent: 999
! minexponent: -999
! precision: 9
! plux301 plus 12345678000  -> 1.23456780E+10 Rounded
! plux302 plus 1234567800   -> 1.23456780E+9 Rounded
! plux303 plus 1234567890   -> 1.23456789E+9 Rounded
! plux304 plus 1234567891   -> 1.23456789E+9 Inexact Rounded
! plux305 plus 12345678901  -> 1.23456789E+10 Inexact Rounded
! plux306 plus 1234567896   -> 1.23456790E+9 Inexact Rounded
! 
! -- still checking
! precision: 15
! plux321 plus 12345678000  -> 12345678000
! plux322 plus 1234567800   -> 1234567800
! plux323 plus 1234567890   -> 1234567890
! plux324 plus 1234567891   -> 1234567891
! plux325 plus 12345678901  -> 12345678901
! plux326 plus 1234567896   -> 1234567896
! precision: 9
! 
! -- Null tests
! plu900 plus  # -> NaN Invalid_operation
! 

Index: power.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/power.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** power.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- power.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,651 ****
! ----------------------------------------------------------------------
! -- power.decTest -- decimal exponentiation                            --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
[...1273 lines suppressed...]
! powx742 power 1234567800  1 -> 1234567800
! powx743 power 1234567890  1 -> 1234567890
! powx744 power 1234567891  1 -> 1234567891
! powx745 power 12345678901 1 -> 12345678901
! powx746 power 1234567896  1 -> 1234567896
! powx747 power 1 12345678000  -> NaN Invalid_operation
! powx748 power 1 -1234567896  -> NaN Invalid_operation
! powx749 power 1 1000000000   -> NaN Invalid_operation
! powx740 power 1 -1000000000  -> NaN Invalid_operation
! 
! -- check for double-rounded subnormals
! precision:   5
! maxexponent: 79
! minexponent: -79
! powx750 power     1.2347E-40  2      ->  1.524E-80 Inexact Rounded Subnormal Underflow
! 
! -- Null tests
! powx900 power  1 # -> NaN Invalid_operation
! powx901 power  # 1 -> NaN Invalid_operation
! 

Index: quantize.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/quantize.decTest,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** quantize.decTest	6 Feb 2004 16:56:03 -0000	1.3
--- quantize.decTest	21 Jun 2004 21:48:22 -0000	1.4
***************
*** 1,779 ****
! ------------------------------------------------------------------------
! -- quantize.decTest -- decimal quantize operation                     --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
[...1530 lines suppressed...]
! quax846 quantize   0  1e-1000000000 -> 0E-1000000000
! quax847 quantize   0  1e-1000000001 -> 0E-1000000001
! quax848 quantize   0  1e-1000000002 -> 0E-1000000002
! quax849 quantize   0  1e-1000000003 -> 0E-1000000003
! quax850 quantize   0  1e-1000000004 -> 0E-1000000004
! quax851 quantize   0  1e-1000000005 -> 0E-1000000005
! quax852 quantize   0  1e-1000000006 -> 0E-1000000006
! quax853 quantize   0  1e-1000000007 -> 0E-1000000007
! quax854 quantize   0  1e-1000000008 -> NaN Invalid_operation
! 
! quax861 quantize   1  1e+2147483649 -> NaN Invalid_operation
! quax862 quantize   1  1e+2147483648 -> NaN Invalid_operation
! quax863 quantize   1  1e+2147483647 -> NaN Invalid_operation
! quax864 quantize   1  1e-2147483647 -> NaN Invalid_operation
! quax865 quantize   1  1e-2147483648 -> NaN Invalid_operation
! quax866 quantize   1  1e-2147483649 -> NaN Invalid_operation
! 
! -- Null tests
! quax900 quantize 10    # -> NaN Invalid_operation
! quax901 quantize  # 1e10 -> NaN Invalid_operation

Index: randomBound32.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/randomBound32.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** randomBound32.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- randomBound32.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,2443 ****
! ------------------------------------------------------------------------
! -- randomBound32.decTest -- decimal testcases -- boundaries near 32   --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
[...4857 lines suppressed...]
! mulx3498 multiply 91936087917435.5974889495278215874 -67080823344.8903392584327136082486E-757 -> -6.16714847260980448099292763939423E-733 Inexact Rounded
! powx3498 power 91936087917435.5974889495278215874 -7 -> 1.80134899939035708719659065082630E-98 Inexact Rounded
! remx3498 remainder 91936087917435.5974889495278215874 -67080823344.8903392584327136082486E-757 -> NaN Division_impossible
! subx3498 subtract 91936087917435.5974889495278215874 -67080823344.8903392584327136082486E-757 -> 91936087917435.5974889495278215874 Inexact Rounded
! addx3499 add -07345.6422518528556136521417259811E-600 41188325.7041362608934957584583381E-763 -> -7.34564225185285561365214172598110E-597 Inexact Rounded
! comx3499 compare -07345.6422518528556136521417259811E-600 41188325.7041362608934957584583381E-763 -> -1
! divx3499 divide -07345.6422518528556136521417259811E-600 41188325.7041362608934957584583381E-763 -> -1.78342822299163842247184303878022E+159 Inexact Rounded
! dvix3499 divideint -07345.6422518528556136521417259811E-600 41188325.7041362608934957584583381E-763 -> NaN Division_impossible
! mulx3499 multiply -07345.6422518528556136521417259811E-600 41188325.7041362608934957584583381E-763 -> -3.02554705575380338274126867655676E-1352 Inexact Rounded
! powx3499 power -07345.6422518528556136521417259811E-600 4 -> 2.91151541552217582082937236255996E-2385 Inexact Rounded
! remx3499 remainder -07345.6422518528556136521417259811E-600 41188325.7041362608934957584583381E-763 -> NaN Division_impossible
! subx3499 subtract -07345.6422518528556136521417259811E-600 41188325.7041362608934957584583381E-763 -> -7.34564225185285561365214172598110E-597 Inexact Rounded
! addx3500 add -253280724.939458021588167965038184 616988.426425908872398170896375634E+396 -> 6.16988426425908872398170896375634E+401 Inexact Rounded
! comx3500 compare -253280724.939458021588167965038184 616988.426425908872398170896375634E+396 -> -1
! divx3500 divide -253280724.939458021588167965038184 616988.426425908872398170896375634E+396 -> -4.10511306357337753351655511866170E-394 Inexact Rounded
! dvix3500 divideint -253280724.939458021588167965038184 616988.426425908872398170896375634E+396 -> -0
! mulx3500 multiply -253280724.939458021588167965038184 616988.426425908872398170896375634E+396 -> -1.56271275924409657991913620522315E+410 Inexact Rounded
! powx3500 power -253280724.939458021588167965038184 6 -> 2.64005420221406808782284459794424E+50 Inexact Rounded
! remx3500 remainder -253280724.939458021588167965038184 616988.426425908872398170896375634E+396 -> -253280724.939458021588167965038184
! subx3500 subtract -253280724.939458021588167965038184 616988.426425908872398170896375634E+396 -> -6.16988426425908872398170896375634E+401 Inexact Rounded

Index: randoms.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/randoms.decTest,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** randoms.decTest	20 Jun 2004 01:53:06 -0000	1.6
--- randoms.decTest	21 Jun 2004 21:48:22 -0000	1.7
***************
*** 18,22 ****
  --   mfc at uk.ibm.com                                                   --
  ------------------------------------------------------------------------
! version: 2.35
  
  extended:    1
--- 18,22 ----
  --   mfc at uk.ibm.com                                                   --
  ------------------------------------------------------------------------
! version: 2.38
  
  extended:    1

Index: remainder.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/remainder.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** remainder.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- remainder.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,518 ****
! ------------------------------------------------------------------------
! -- remainder.decTest -- decimal remainder                             --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
[...1118 lines suppressed...]
! 
! remx980 remainder 123e1 1000E999999 -> 1.23E+3  -- 123E+1 internally
! 
! -- overflow and underflow tests [from divide]
! precision: 9
! maxexponent: 999999999
! minexponent: -999999999
! remx990 remainder +1.23456789012345E-0 9E+999999999 -> 1.23456789 Inexact Rounded
! remx991 remainder 9E+999999999 +0.23456789012345E-0 -> NaN Division_impossible
! remx992 remainder +0.100 9E+999999999               -> 0.100
! remx993 remainder 9E-999999999 +9.100               -> 9E-999999999
! remx995 remainder -1.23456789012345E-0 9E+999999999 -> -1.23456789 Inexact Rounded
! remx996 remainder 9E+999999999 -0.83456789012345E-0 -> NaN Division_impossible
! remx997 remainder -0.100 9E+999999999               -> -0.100
! remx998 remainder 9E-999999999 -9.100               -> 9E-999999999
! 
! -- Null tests
! remx1000 remainder 10  # -> NaN Invalid_operation
! remx1001 remainder  # 10 -> NaN Invalid_operation
! 

Index: remainderNear.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/remainderNear.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** remainderNear.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- remainderNear.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,560 ****
! ------------------------------------------------------------------------
! -- remainderNear.decTest -- decimal remainder-near (IEEE remainder)   --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
[...1091 lines suppressed...]
! rmnx811 remaindernear 1234567896  10  -> -4
! rmnx812 remaindernear 1 1234567896    -> 1
! 
! precision: 15
! rmnx841 remaindernear 12345678000 100 -> 0
! rmnx842 remaindernear 1 12345678000   -> 1
! rmnx843 remaindernear 1234567800  10  -> 0
! rmnx844 remaindernear 1 1234567800    -> 1
! rmnx845 remaindernear 1234567890  10  -> 0
! rmnx846 remaindernear 1 1234567890    -> 1
! rmnx847 remaindernear 1234567891  10  -> 1
! rmnx848 remaindernear 1 1234567891    -> 1
! rmnx849 remaindernear 12345678901 100 -> 1
! rmnx850 remaindernear 1 12345678901   -> 1
! rmnx851 remaindernear 1234567896  10  -> -4
! rmnx852 remaindernear 1 1234567896    -> 1
! 
! -- Null tests
! rmnx900 remaindernear 10  # -> NaN Invalid_operation
! rmnx901 remaindernear  # 10 -> NaN Invalid_operation

Index: rounding.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/rounding.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** rounding.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- rounding.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,1079 ****
! ------------------------------------------------------------------------
! -- rounding.decTest -- decimal rounding modes testcases               --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
[...2129 lines suppressed...]
! rmex401 multiply  9.999E+999999999 10 ->  Infinity Overflow Inexact Rounded
! rounding: half_down
! rmex402 multiply -9.999E+999999999 10 -> -Infinity Overflow Inexact Rounded
! rmex403 multiply  9.999E+999999999 10 ->  Infinity Overflow Inexact Rounded
! rounding: half_even
! rmex404 multiply -9.999E+999999999 10 -> -Infinity Overflow Inexact Rounded
! rmex405 multiply  9.999E+999999999 10 ->  Infinity Overflow Inexact Rounded
! rounding: floor
! rmex406 multiply -9.999E+999999999 10 -> -Infinity Overflow Inexact Rounded
! rmex407 multiply  9.999E+999999999 10 ->  9.99999999E+999999999 Overflow Inexact Rounded
! rounding: ceiling
! rmex408 multiply -9.999E+999999999 10 -> -9.99999999E+999999999 Overflow Inexact Rounded
! rmex409 multiply  9.999E+999999999 10 ->  Infinity Overflow Inexact Rounded
! rounding: up
! rmex410 multiply -9.999E+999999999 10 -> -Infinity Overflow Inexact Rounded
! rmex411 multiply  9.999E+999999999 10 ->  Infinity Overflow Inexact Rounded
! rounding: down
! rmex412 multiply -9.999E+999999999 10 -> -9.99999999E+999999999 Overflow Inexact Rounded
! rmex413 multiply  9.999E+999999999 10 ->  9.99999999E+999999999 Overflow Inexact Rounded
! 

Index: samequantum.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/samequantum.decTest,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** samequantum.decTest	6 Feb 2004 16:56:03 -0000	1.1
--- samequantum.decTest	21 Jun 2004 21:48:22 -0000	1.2
***************
*** 1,353 ****
! ------------------------------------------------------------------------
! -- samequantum.decTest -- check quantums match                        --
! -- Copyright (c) IBM Corporation, 2001, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.35
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minExponent: -999
! 
! samq001 samequantum  0      0      ->  1
! samq002 samequantum  0      1      ->  1
! samq003 samequantum  1      0      ->  1
! samq004 samequantum  1      1      ->  1
! 
! samq011 samequantum  10     1E+1   -> 0
! samq012 samequantum  10E+1  10E+1  -> 1
! samq013 samequantum  100    10E+1  -> 0
! samq014 samequantum  100    1E+2   -> 0
! samq015 samequantum  0.1    1E-2   -> 0
! samq016 samequantum  0.1    1E-1   -> 1
! samq017 samequantum  0.1    1E-0   -> 0
! samq018 samequantum  999    999    -> 1
! samq019 samequantum  999E-1 99.9   -> 1
! samq020 samequantum  111E-1 22.2   -> 1
! samq021 samequantum  111E-1 1234.2 -> 1
! 
! -- zeros
! samq030 samequantum  0.0    1.1    -> 1
! samq031 samequantum  0.0    1.11   -> 0
! samq032 samequantum  0.0    0      -> 0
! samq033 samequantum  0.0    0.0    -> 1
! samq034 samequantum  0.0    0.00   -> 0
! samq035 samequantum  0E+1   0E+0   -> 0
! samq036 samequantum  0E+1   0E+1   -> 1
! samq037 samequantum  0E+1   0E+2   -> 0
! samq038 samequantum  0E-17  0E-16  -> 0
! samq039 samequantum  0E-17  0E-17  -> 1
! samq040 samequantum  0E-17  0E-18  -> 0
! samq041 samequantum  0E-17  0.0E-15 -> 0
! samq042 samequantum  0E-17  0.0E-16 -> 1
! samq043 samequantum  0E-17  0.0E-17 -> 0
! samq044 samequantum -0E-17  0.0E-16 -> 1
! samq045 samequantum  0E-17 -0.0E-17 -> 0
! samq046 samequantum  0E-17 -0.0E-16 -> 1
! samq047 samequantum -0E-17  0.0E-17 -> 0
! samq048 samequantum -0E-17 -0.0E-16 -> 1
! samq049 samequantum -0E-17 -0.0E-17 -> 0
! 
! -- specials & combinations
! 
! samq0110 samequantum  -Inf    -Inf   -> 1
! samq0111 samequantum  -Inf     Inf   -> 1
! samq0112 samequantum  -Inf     NaN   -> 0
! samq0113 samequantum  -Inf    -7E+3  -> 0
! samq0114 samequantum  -Inf    -7     -> 0
! samq0115 samequantum  -Inf    -7E-3  -> 0
! samq0116 samequantum  -Inf    -0E-3  -> 0
! samq0117 samequantum  -Inf    -0     -> 0
! samq0118 samequantum  -Inf    -0E+3  -> 0
! samq0119 samequantum  -Inf     0E-3  -> 0
! samq0120 samequantum  -Inf     0     -> 0
! samq0121 samequantum  -Inf     0E+3  -> 0
! samq0122 samequantum  -Inf     7E-3  -> 0
! samq0123 samequantum  -Inf     7     -> 0
! samq0124 samequantum  -Inf     7E+3  -> 0
! samq0125 samequantum  -Inf     sNaN  -> 0
! 
! samq0210 samequantum   Inf    -Inf   -> 1
! samq0211 samequantum   Inf     Inf   -> 1
! samq0212 samequantum   Inf     NaN   -> 0
! samq0213 samequantum   Inf    -7E+3  -> 0
! samq0214 samequantum   Inf    -7     -> 0
! samq0215 samequantum   Inf    -7E-3  -> 0
! samq0216 samequantum   Inf    -0E-3  -> 0
! samq0217 samequantum   Inf    -0     -> 0
! samq0218 samequantum   Inf    -0E+3  -> 0
! samq0219 samequantum   Inf     0E-3  -> 0
! samq0220 samequantum   Inf     0     -> 0
! samq0221 samequantum   Inf     0E+3  -> 0
! samq0222 samequantum   Inf     7E-3  -> 0
! samq0223 samequantum   Inf     7     -> 0
! samq0224 samequantum   Inf     7E+3  -> 0
! samq0225 samequantum   Inf     sNaN  -> 0
! 
! samq0310 samequantum   NaN    -Inf   -> 0
! samq0311 samequantum   NaN     Inf   -> 0
! samq0312 samequantum   NaN     NaN   -> 1
! samq0313 samequantum   NaN    -7E+3  -> 0
! samq0314 samequantum   NaN    -7     -> 0
! samq0315 samequantum   NaN    -7E-3  -> 0
! samq0316 samequantum   NaN    -0E-3  -> 0
! samq0317 samequantum   NaN    -0     -> 0
! samq0318 samequantum   NaN    -0E+3  -> 0
! samq0319 samequantum   NaN     0E-3  -> 0
! samq0320 samequantum   NaN     0     -> 0
! samq0321 samequantum   NaN     0E+3  -> 0
! samq0322 samequantum   NaN     7E-3  -> 0
! samq0323 samequantum   NaN     7     -> 0
! samq0324 samequantum   NaN     7E+3  -> 0
! samq0325 samequantum   NaN     sNaN  -> 1
! 
! samq0410 samequantum  -7E+3    -Inf   -> 0
! samq0411 samequantum  -7E+3     Inf   -> 0
! samq0412 samequantum  -7E+3     NaN   -> 0
! samq0413 samequantum  -7E+3    -7E+3  -> 1
! samq0414 samequantum  -7E+3    -7     -> 0
! samq0415 samequantum  -7E+3    -7E-3  -> 0
! samq0416 samequantum  -7E+3    -0E-3  -> 0
! samq0417 samequantum  -7E+3    -0     -> 0
! samq0418 samequantum  -7E+3    -0E+3  -> 1
! samq0419 samequantum  -7E+3     0E-3  -> 0
! samq0420 samequantum  -7E+3     0     -> 0
! samq0421 samequantum  -7E+3     0E+3  -> 1
! samq0422 samequantum  -7E+3     7E-3  -> 0
! samq0423 samequantum  -7E+3     7     -> 0
! samq0424 samequantum  -7E+3     7E+3  -> 1
! samq0425 samequantum  -7E+3     sNaN  -> 0
! 
! samq0510 samequantum  -7      -Inf   -> 0
! samq0511 samequantum  -7       Inf   -> 0
! samq0512 samequantum  -7       NaN   -> 0
! samq0513 samequantum  -7      -7E+3  -> 0
! samq0514 samequantum  -7      -7     -> 1
! samq0515 samequantum  -7      -7E-3  -> 0
! samq0516 samequantum  -7      -0E-3  -> 0
! samq0517 samequantum  -7      -0     -> 1
! samq0518 samequantum  -7      -0E+3  -> 0
! samq0519 samequantum  -7       0E-3  -> 0
! samq0520 samequantum  -7       0     -> 1
! samq0521 samequantum  -7       0E+3  -> 0
! samq0522 samequantum  -7       7E-3  -> 0
! samq0523 samequantum  -7       7     -> 1
! samq0524 samequantum  -7       7E+3  -> 0
! samq0525 samequantum  -7       sNaN  -> 0
! 
! samq0610 samequantum  -7E-3    -Inf   -> 0
! samq0611 samequantum  -7E-3     Inf   -> 0
! samq0612 samequantum  -7E-3     NaN   -> 0
! samq0613 samequantum  -7E-3    -7E+3  -> 0
! samq0614 samequantum  -7E-3    -7     -> 0
! samq0615 samequantum  -7E-3    -7E-3  -> 1
! samq0616 samequantum  -7E-3    -0E-3  -> 1
! samq0617 samequantum  -7E-3    -0     -> 0
! samq0618 samequantum  -7E-3    -0E+3  -> 0
! samq0619 samequantum  -7E-3     0E-3  -> 1
! samq0620 samequantum  -7E-3     0     -> 0
! samq0621 samequantum  -7E-3     0E+3  -> 0
! samq0622 samequantum  -7E-3     7E-3  -> 1
! samq0623 samequantum  -7E-3     7     -> 0
! samq0624 samequantum  -7E-3     7E+3  -> 0
! samq0625 samequantum  -7E-3     sNaN  -> 0
! 
! samq0710 samequantum  -0E-3    -Inf   -> 0
! samq0711 samequantum  -0E-3     Inf   -> 0
! samq0712 samequantum  -0E-3     NaN   -> 0
! samq0713 samequantum  -0E-3    -7E+3  -> 0
! samq0714 samequantum  -0E-3    -7     -> 0
! samq0715 samequantum  -0E-3    -7E-3  -> 1
! samq0716 samequantum  -0E-3    -0E-3  -> 1
! samq0717 samequantum  -0E-3    -0     -> 0
! samq0718 samequantum  -0E-3    -0E+3  -> 0
! samq0719 samequantum  -0E-3     0E-3  -> 1
! samq0720 samequantum  -0E-3     0     -> 0
! samq0721 samequantum  -0E-3     0E+3  -> 0
! samq0722 samequantum  -0E-3     7E-3  -> 1
! samq0723 samequantum  -0E-3     7     -> 0
! samq0724 samequantum  -0E-3     7E+3  -> 0
! samq0725 samequantum  -0E-3     sNaN  -> 0
! 
! samq0810 samequantum  -0      -Inf   -> 0
! samq0811 samequantum  -0       Inf   -> 0
! samq0812 samequantum  -0       NaN   -> 0
! samq0813 samequantum  -0      -7E+3  -> 0
! samq0814 samequantum  -0      -7     -> 1
! samq0815 samequantum  -0      -7E-3  -> 0
! samq0816 samequantum  -0      -0E-3  -> 0
! samq0817 samequantum  -0      -0     -> 1
! samq0818 samequantum  -0      -0E+3  -> 0
! samq0819 samequantum  -0       0E-3  -> 0
! samq0820 samequantum  -0       0     -> 1
! samq0821 samequantum  -0       0E+3  -> 0
! samq0822 samequantum  -0       7E-3  -> 0
! samq0823 samequantum  -0       7     -> 1
! samq0824 samequantum  -0       7E+3  -> 0
! samq0825 samequantum  -0       sNaN  -> 0
! 
! samq0910 samequantum  -0E+3    -Inf   -> 0
! samq0911 samequantum  -0E+3     Inf   -> 0
! samq0912 samequantum  -0E+3     NaN   -> 0
! samq0913 samequantum  -0E+3    -7E+3  -> 1
! samq0914 samequantum  -0E+3    -7     -> 0
! samq0915 samequantum  -0E+3    -7E-3  -> 0
! samq0916 samequantum  -0E+3    -0E-3  -> 0
! samq0917 samequantum  -0E+3    -0     -> 0
! samq0918 samequantum  -0E+3    -0E+3  -> 1
! samq0919 samequantum  -0E+3     0E-3  -> 0
! samq0920 samequantum  -0E+3     0     -> 0
! samq0921 samequantum  -0E+3     0E+3  -> 1
! samq0922 samequantum  -0E+3     7E-3  -> 0
! samq0923 samequantum  -0E+3     7     -> 0
! samq0924 samequantum  -0E+3     7E+3  -> 1
! samq0925 samequantum  -0E+3     sNaN  -> 0
! 
! samq1110 samequantum  0E-3    -Inf   -> 0
! samq1111 samequantum  0E-3     Inf   -> 0
! samq1112 samequantum  0E-3     NaN   -> 0
! samq1113 samequantum  0E-3    -7E+3  -> 0
! samq1114 samequantum  0E-3    -7     -> 0
! samq1115 samequantum  0E-3    -7E-3  -> 1
! samq1116 samequantum  0E-3    -0E-3  -> 1
! samq1117 samequantum  0E-3    -0     -> 0
! samq1118 samequantum  0E-3    -0E+3  -> 0
! samq1119 samequantum  0E-3     0E-3  -> 1
! samq1120 samequantum  0E-3     0     -> 0
! samq1121 samequantum  0E-3     0E+3  -> 0
! samq1122 samequantum  0E-3     7E-3  -> 1
! samq1123 samequantum  0E-3     7     -> 0
! samq1124 samequantum  0E-3     7E+3  -> 0
! samq1125 samequantum  0E-3     sNaN  -> 0
! 
! samq1210 samequantum  0       -Inf   -> 0
! samq1211 samequantum  0        Inf   -> 0
! samq1212 samequantum  0        NaN   -> 0
! samq1213 samequantum  0       -7E+3  -> 0
! samq1214 samequantum  0       -7     -> 1
! samq1215 samequantum  0       -7E-3  -> 0
! samq1216 samequantum  0       -0E-3  -> 0
! samq1217 samequantum  0       -0     -> 1
! samq1218 samequantum  0       -0E+3  -> 0
! samq1219 samequantum  0        0E-3  -> 0
! samq1220 samequantum  0        0     -> 1
! samq1221 samequantum  0        0E+3  -> 0
! samq1222 samequantum  0        7E-3  -> 0
! samq1223 samequantum  0        7     -> 1
! samq1224 samequantum  0        7E+3  -> 0
! samq1225 samequantum  0        sNaN  -> 0
! 
! samq1310 samequantum  0E+3    -Inf   -> 0
! samq1311 samequantum  0E+3     Inf   -> 0
! samq1312 samequantum  0E+3     NaN   -> 0
! samq1313 samequantum  0E+3    -7E+3  -> 1
! samq1314 samequantum  0E+3    -7     -> 0
! samq1315 samequantum  0E+3    -7E-3  -> 0
! samq1316 samequantum  0E+3    -0E-3  -> 0
! samq1317 samequantum  0E+3    -0     -> 0
! samq1318 samequantum  0E+3    -0E+3  -> 1
! samq1319 samequantum  0E+3     0E-3  -> 0
! samq1320 samequantum  0E+3     0     -> 0
! samq1321 samequantum  0E+3     0E+3  -> 1
! samq1322 samequantum  0E+3     7E-3  -> 0
! samq1323 samequantum  0E+3     7     -> 0
! samq1324 samequantum  0E+3     7E+3  -> 1
! samq1325 samequantum  0E+3     sNaN  -> 0
! 
! samq1410 samequantum  7E-3    -Inf   -> 0
! samq1411 samequantum  7E-3     Inf   -> 0
! samq1412 samequantum  7E-3     NaN   -> 0
! samq1413 samequantum  7E-3    -7E+3  -> 0
! samq1414 samequantum  7E-3    -7     -> 0
! samq1415 samequantum  7E-3    -7E-3  -> 1
! samq1416 samequantum  7E-3    -0E-3  -> 1
! samq1417 samequantum  7E-3    -0     -> 0
! samq1418 samequantum  7E-3    -0E+3  -> 0
! samq1419 samequantum  7E-3     0E-3  -> 1
! samq1420 samequantum  7E-3     0     -> 0
! samq1421 samequantum  7E-3     0E+3  -> 0
! samq1422 samequantum  7E-3     7E-3  -> 1
! samq1423 samequantum  7E-3     7     -> 0
! samq1424 samequantum  7E-3     7E+3  -> 0
! samq1425 samequantum  7E-3     sNaN  -> 0
! 
! samq1510 samequantum  7      -Inf   -> 0
! samq1511 samequantum  7       Inf   -> 0
! samq1512 samequantum  7       NaN   -> 0
! samq1513 samequantum  7      -7E+3  -> 0
! samq1514 samequantum  7      -7     -> 1
! samq1515 samequantum  7      -7E-3  -> 0
! samq1516 samequantum  7      -0E-3  -> 0
! samq1517 samequantum  7      -0     -> 1
! samq1518 samequantum  7      -0E+3  -> 0
! samq1519 samequantum  7       0E-3  -> 0
! samq1520 samequantum  7       0     -> 1
! samq1521 samequantum  7       0E+3  -> 0
! samq1522 samequantum  7       7E-3  -> 0
! samq1523 samequantum  7       7     -> 1
! samq1524 samequantum  7       7E+3  -> 0
! samq1525 samequantum  7       sNaN  -> 0
! 
! samq1610 samequantum  7E+3    -Inf   -> 0
! samq1611 samequantum  7E+3     Inf   -> 0
! samq1612 samequantum  7E+3     NaN   -> 0
! samq1613 samequantum  7E+3    -7E+3  -> 1
! samq1614 samequantum  7E+3    -7     -> 0
! samq1615 samequantum  7E+3    -7E-3  -> 0
! samq1616 samequantum  7E+3    -0E-3  -> 0
! samq1617 samequantum  7E+3    -0     -> 0
! samq1618 samequantum  7E+3    -0E+3  -> 1
! samq1619 samequantum  7E+3     0E-3  -> 0
! samq1620 samequantum  7E+3     0     -> 0
! samq1621 samequantum  7E+3     0E+3  -> 1
! samq1622 samequantum  7E+3     7E-3  -> 0
! samq1623 samequantum  7E+3     7     -> 0
! samq1624 samequantum  7E+3     7E+3  -> 1
! samq1625 samequantum  7E+3     sNaN  -> 0
! 
! samq1710 samequantum  sNaN    -Inf   -> 0
! samq1711 samequantum  sNaN     Inf   -> 0
! samq1712 samequantum  sNaN     NaN   -> 1
! samq1713 samequantum  sNaN    -7E+3  -> 0
! samq1714 samequantum  sNaN    -7     -> 0
! samq1715 samequantum  sNaN    -7E-3  -> 0
! samq1716 samequantum  sNaN    -0E-3  -> 0
! samq1717 samequantum  sNaN    -0     -> 0
! samq1718 samequantum  sNaN    -0E+3  -> 0
! samq1719 samequantum  sNaN     0E-3  -> 0
! samq1720 samequantum  sNaN     0     -> 0
! samq1721 samequantum  sNaN     0E+3  -> 0
! samq1722 samequantum  sNaN     7E-3  -> 0
! samq1723 samequantum  sNaN     7     -> 0
! samq1724 samequantum  sNaN     7E+3  -> 0
! samq1725 samequantum  sNaN     sNaN  -> 1
! -- noisy NaNs
! samq1730 samequantum  sNaN3    sNaN3 -> 1
! samq1731 samequantum  sNaN3    sNaN4 -> 1
! samq1732 samequantum   NaN3     NaN3 -> 1
! samq1733 samequantum   NaN3     NaN4 -> 1
! samq1734 samequantum  sNaN3     3    -> 0
! samq1735 samequantum   NaN3     3    -> 0
! samq1736 samequantum      4    sNaN4 -> 0
! samq1737 samequantum      3     NaN3 -> 0
! samq1738 samequantum    Inf    sNaN4 -> 0
! samq1739 samequantum   -Inf     NaN3 -> 0
! 
! 
! 
--- 1,353 ----
! ------------------------------------------------------------------------
! -- samequantum.decTest -- check quantums match                        --
! -- Copyright (c) IBM Corporation, 2001, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.38
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minExponent: -999
! 
! samq001 samequantum  0      0      ->  1
! samq002 samequantum  0      1      ->  1
! samq003 samequantum  1      0      ->  1
! samq004 samequantum  1      1      ->  1
! 
! samq011 samequantum  10     1E+1   -> 0
! samq012 samequantum  10E+1  10E+1  -> 1
! samq013 samequantum  100    10E+1  -> 0
! samq014 samequantum  100    1E+2   -> 0
! samq015 samequantum  0.1    1E-2   -> 0
! samq016 samequantum  0.1    1E-1   -> 1
! samq017 samequantum  0.1    1E-0   -> 0
! samq018 samequantum  999    999    -> 1
! samq019 samequantum  999E-1 99.9   -> 1
! samq020 samequantum  111E-1 22.2   -> 1
! samq021 samequantum  111E-1 1234.2 -> 1
! 
! -- zeros
! samq030 samequantum  0.0    1.1    -> 1
! samq031 samequantum  0.0    1.11   -> 0
! samq032 samequantum  0.0    0      -> 0
! samq033 samequantum  0.0    0.0    -> 1
! samq034 samequantum  0.0    0.00   -> 0
! samq035 samequantum  0E+1   0E+0   -> 0
! samq036 samequantum  0E+1   0E+1   -> 1
! samq037 samequantum  0E+1   0E+2   -> 0
! samq038 samequantum  0E-17  0E-16  -> 0
! samq039 samequantum  0E-17  0E-17  -> 1
! samq040 samequantum  0E-17  0E-18  -> 0
! samq041 samequantum  0E-17  0.0E-15 -> 0
! samq042 samequantum  0E-17  0.0E-16 -> 1
! samq043 samequantum  0E-17  0.0E-17 -> 0
! samq044 samequantum -0E-17  0.0E-16 -> 1
! samq045 samequantum  0E-17 -0.0E-17 -> 0
! samq046 samequantum  0E-17 -0.0E-16 -> 1
! samq047 samequantum -0E-17  0.0E-17 -> 0
! samq048 samequantum -0E-17 -0.0E-16 -> 1
! samq049 samequantum -0E-17 -0.0E-17 -> 0
! 
! -- specials & combinations
! 
! samq0110 samequantum  -Inf    -Inf   -> 1
! samq0111 samequantum  -Inf     Inf   -> 1
! samq0112 samequantum  -Inf     NaN   -> 0
! samq0113 samequantum  -Inf    -7E+3  -> 0
! samq0114 samequantum  -Inf    -7     -> 0
! samq0115 samequantum  -Inf    -7E-3  -> 0
! samq0116 samequantum  -Inf    -0E-3  -> 0
! samq0117 samequantum  -Inf    -0     -> 0
! samq0118 samequantum  -Inf    -0E+3  -> 0
! samq0119 samequantum  -Inf     0E-3  -> 0
! samq0120 samequantum  -Inf     0     -> 0
! samq0121 samequantum  -Inf     0E+3  -> 0
! samq0122 samequantum  -Inf     7E-3  -> 0
! samq0123 samequantum  -Inf     7     -> 0
! samq0124 samequantum  -Inf     7E+3  -> 0
! samq0125 samequantum  -Inf     sNaN  -> 0
! 
! samq0210 samequantum   Inf    -Inf   -> 1
! samq0211 samequantum   Inf     Inf   -> 1
! samq0212 samequantum   Inf     NaN   -> 0
! samq0213 samequantum   Inf    -7E+3  -> 0
! samq0214 samequantum   Inf    -7     -> 0
! samq0215 samequantum   Inf    -7E-3  -> 0
! samq0216 samequantum   Inf    -0E-3  -> 0
! samq0217 samequantum   Inf    -0     -> 0
! samq0218 samequantum   Inf    -0E+3  -> 0
! samq0219 samequantum   Inf     0E-3  -> 0
! samq0220 samequantum   Inf     0     -> 0
! samq0221 samequantum   Inf     0E+3  -> 0
! samq0222 samequantum   Inf     7E-3  -> 0
! samq0223 samequantum   Inf     7     -> 0
! samq0224 samequantum   Inf     7E+3  -> 0
! samq0225 samequantum   Inf     sNaN  -> 0
! 
! samq0310 samequantum   NaN    -Inf   -> 0
! samq0311 samequantum   NaN     Inf   -> 0
! samq0312 samequantum   NaN     NaN   -> 1
! samq0313 samequantum   NaN    -7E+3  -> 0
! samq0314 samequantum   NaN    -7     -> 0
! samq0315 samequantum   NaN    -7E-3  -> 0
! samq0316 samequantum   NaN    -0E-3  -> 0
! samq0317 samequantum   NaN    -0     -> 0
! samq0318 samequantum   NaN    -0E+3  -> 0
! samq0319 samequantum   NaN     0E-3  -> 0
! samq0320 samequantum   NaN     0     -> 0
! samq0321 samequantum   NaN     0E+3  -> 0
! samq0322 samequantum   NaN     7E-3  -> 0
! samq0323 samequantum   NaN     7     -> 0
! samq0324 samequantum   NaN     7E+3  -> 0
! samq0325 samequantum   NaN     sNaN  -> 1
! 
! samq0410 samequantum  -7E+3    -Inf   -> 0
! samq0411 samequantum  -7E+3     Inf   -> 0
! samq0412 samequantum  -7E+3     NaN   -> 0
! samq0413 samequantum  -7E+3    -7E+3  -> 1
! samq0414 samequantum  -7E+3    -7     -> 0
! samq0415 samequantum  -7E+3    -7E-3  -> 0
! samq0416 samequantum  -7E+3    -0E-3  -> 0
! samq0417 samequantum  -7E+3    -0     -> 0
! samq0418 samequantum  -7E+3    -0E+3  -> 1
! samq0419 samequantum  -7E+3     0E-3  -> 0
! samq0420 samequantum  -7E+3     0     -> 0
! samq0421 samequantum  -7E+3     0E+3  -> 1
! samq0422 samequantum  -7E+3     7E-3  -> 0
! samq0423 samequantum  -7E+3     7     -> 0
! samq0424 samequantum  -7E+3     7E+3  -> 1
! samq0425 samequantum  -7E+3     sNaN  -> 0
! 
! samq0510 samequantum  -7      -Inf   -> 0
! samq0511 samequantum  -7       Inf   -> 0
! samq0512 samequantum  -7       NaN   -> 0
! samq0513 samequantum  -7      -7E+3  -> 0
! samq0514 samequantum  -7      -7     -> 1
! samq0515 samequantum  -7      -7E-3  -> 0
! samq0516 samequantum  -7      -0E-3  -> 0
! samq0517 samequantum  -7      -0     -> 1
! samq0518 samequantum  -7      -0E+3  -> 0
! samq0519 samequantum  -7       0E-3  -> 0
! samq0520 samequantum  -7       0     -> 1
! samq0521 samequantum  -7       0E+3  -> 0
! samq0522 samequantum  -7       7E-3  -> 0
! samq0523 samequantum  -7       7     -> 1
! samq0524 samequantum  -7       7E+3  -> 0
! samq0525 samequantum  -7       sNaN  -> 0
! 
! samq0610 samequantum  -7E-3    -Inf   -> 0
! samq0611 samequantum  -7E-3     Inf   -> 0
! samq0612 samequantum  -7E-3     NaN   -> 0
! samq0613 samequantum  -7E-3    -7E+3  -> 0
! samq0614 samequantum  -7E-3    -7     -> 0
! samq0615 samequantum  -7E-3    -7E-3  -> 1
! samq0616 samequantum  -7E-3    -0E-3  -> 1
! samq0617 samequantum  -7E-3    -0     -> 0
! samq0618 samequantum  -7E-3    -0E+3  -> 0
! samq0619 samequantum  -7E-3     0E-3  -> 1
! samq0620 samequantum  -7E-3     0     -> 0
! samq0621 samequantum  -7E-3     0E+3  -> 0
! samq0622 samequantum  -7E-3     7E-3  -> 1
! samq0623 samequantum  -7E-3     7     -> 0
! samq0624 samequantum  -7E-3     7E+3  -> 0
! samq0625 samequantum  -7E-3     sNaN  -> 0
! 
! samq0710 samequantum  -0E-3    -Inf   -> 0
! samq0711 samequantum  -0E-3     Inf   -> 0
! samq0712 samequantum  -0E-3     NaN   -> 0
! samq0713 samequantum  -0E-3    -7E+3  -> 0
! samq0714 samequantum  -0E-3    -7     -> 0
! samq0715 samequantum  -0E-3    -7E-3  -> 1
! samq0716 samequantum  -0E-3    -0E-3  -> 1
! samq0717 samequantum  -0E-3    -0     -> 0
! samq0718 samequantum  -0E-3    -0E+3  -> 0
! samq0719 samequantum  -0E-3     0E-3  -> 1
! samq0720 samequantum  -0E-3     0     -> 0
! samq0721 samequantum  -0E-3     0E+3  -> 0
! samq0722 samequantum  -0E-3     7E-3  -> 1
! samq0723 samequantum  -0E-3     7     -> 0
! samq0724 samequantum  -0E-3     7E+3  -> 0
! samq0725 samequantum  -0E-3     sNaN  -> 0
! 
! samq0810 samequantum  -0      -Inf   -> 0
! samq0811 samequantum  -0       Inf   -> 0
! samq0812 samequantum  -0       NaN   -> 0
! samq0813 samequantum  -0      -7E+3  -> 0
! samq0814 samequantum  -0      -7     -> 1
! samq0815 samequantum  -0      -7E-3  -> 0
! samq0816 samequantum  -0      -0E-3  -> 0
! samq0817 samequantum  -0      -0     -> 1
! samq0818 samequantum  -0      -0E+3  -> 0
! samq0819 samequantum  -0       0E-3  -> 0
! samq0820 samequantum  -0       0     -> 1
! samq0821 samequantum  -0       0E+3  -> 0
! samq0822 samequantum  -0       7E-3  -> 0
! samq0823 samequantum  -0       7     -> 1
! samq0824 samequantum  -0       7E+3  -> 0
! samq0825 samequantum  -0       sNaN  -> 0
! 
! samq0910 samequantum  -0E+3    -Inf   -> 0
! samq0911 samequantum  -0E+3     Inf   -> 0
! samq0912 samequantum  -0E+3     NaN   -> 0
! samq0913 samequantum  -0E+3    -7E+3  -> 1
! samq0914 samequantum  -0E+3    -7     -> 0
! samq0915 samequantum  -0E+3    -7E-3  -> 0
! samq0916 samequantum  -0E+3    -0E-3  -> 0
! samq0917 samequantum  -0E+3    -0     -> 0
! samq0918 samequantum  -0E+3    -0E+3  -> 1
! samq0919 samequantum  -0E+3     0E-3  -> 0
! samq0920 samequantum  -0E+3     0     -> 0
! samq0921 samequantum  -0E+3     0E+3  -> 1
! samq0922 samequantum  -0E+3     7E-3  -> 0
! samq0923 samequantum  -0E+3     7     -> 0
! samq0924 samequantum  -0E+3     7E+3  -> 1
! samq0925 samequantum  -0E+3     sNaN  -> 0
! 
! samq1110 samequantum  0E-3    -Inf   -> 0
! samq1111 samequantum  0E-3     Inf   -> 0
! samq1112 samequantum  0E-3     NaN   -> 0
! samq1113 samequantum  0E-3    -7E+3  -> 0
! samq1114 samequantum  0E-3    -7     -> 0
! samq1115 samequantum  0E-3    -7E-3  -> 1
! samq1116 samequantum  0E-3    -0E-3  -> 1
! samq1117 samequantum  0E-3    -0     -> 0
! samq1118 samequantum  0E-3    -0E+3  -> 0
! samq1119 samequantum  0E-3     0E-3  -> 1
! samq1120 samequantum  0E-3     0     -> 0
! samq1121 samequantum  0E-3     0E+3  -> 0
! samq1122 samequantum  0E-3     7E-3  -> 1
! samq1123 samequantum  0E-3     7     -> 0
! samq1124 samequantum  0E-3     7E+3  -> 0
! samq1125 samequantum  0E-3     sNaN  -> 0
! 
! samq1210 samequantum  0       -Inf   -> 0
! samq1211 samequantum  0        Inf   -> 0
! samq1212 samequantum  0        NaN   -> 0
! samq1213 samequantum  0       -7E+3  -> 0
! samq1214 samequantum  0       -7     -> 1
! samq1215 samequantum  0       -7E-3  -> 0
! samq1216 samequantum  0       -0E-3  -> 0
! samq1217 samequantum  0       -0     -> 1
! samq1218 samequantum  0       -0E+3  -> 0
! samq1219 samequantum  0        0E-3  -> 0
! samq1220 samequantum  0        0     -> 1
! samq1221 samequantum  0        0E+3  -> 0
! samq1222 samequantum  0        7E-3  -> 0
! samq1223 samequantum  0        7     -> 1
! samq1224 samequantum  0        7E+3  -> 0
! samq1225 samequantum  0        sNaN  -> 0
! 
! samq1310 samequantum  0E+3    -Inf   -> 0
! samq1311 samequantum  0E+3     Inf   -> 0
! samq1312 samequantum  0E+3     NaN   -> 0
! samq1313 samequantum  0E+3    -7E+3  -> 1
! samq1314 samequantum  0E+3    -7     -> 0
! samq1315 samequantum  0E+3    -7E-3  -> 0
! samq1316 samequantum  0E+3    -0E-3  -> 0
! samq1317 samequantum  0E+3    -0     -> 0
! samq1318 samequantum  0E+3    -0E+3  -> 1
! samq1319 samequantum  0E+3     0E-3  -> 0
! samq1320 samequantum  0E+3     0     -> 0
! samq1321 samequantum  0E+3     0E+3  -> 1
! samq1322 samequantum  0E+3     7E-3  -> 0
! samq1323 samequantum  0E+3     7     -> 0
! samq1324 samequantum  0E+3     7E+3  -> 1
! samq1325 samequantum  0E+3     sNaN  -> 0
! 
! samq1410 samequantum  7E-3    -Inf   -> 0
! samq1411 samequantum  7E-3     Inf   -> 0
! samq1412 samequantum  7E-3     NaN   -> 0
! samq1413 samequantum  7E-3    -7E+3  -> 0
! samq1414 samequantum  7E-3    -7     -> 0
! samq1415 samequantum  7E-3    -7E-3  -> 1
! samq1416 samequantum  7E-3    -0E-3  -> 1
! samq1417 samequantum  7E-3    -0     -> 0
! samq1418 samequantum  7E-3    -0E+3  -> 0
! samq1419 samequantum  7E-3     0E-3  -> 1
! samq1420 samequantum  7E-3     0     -> 0
! samq1421 samequantum  7E-3     0E+3  -> 0
! samq1422 samequantum  7E-3     7E-3  -> 1
! samq1423 samequantum  7E-3     7     -> 0
! samq1424 samequantum  7E-3     7E+3  -> 0
! samq1425 samequantum  7E-3     sNaN  -> 0
! 
! samq1510 samequantum  7      -Inf   -> 0
! samq1511 samequantum  7       Inf   -> 0
! samq1512 samequantum  7       NaN   -> 0
! samq1513 samequantum  7      -7E+3  -> 0
! samq1514 samequantum  7      -7     -> 1
! samq1515 samequantum  7      -7E-3  -> 0
! samq1516 samequantum  7      -0E-3  -> 0
! samq1517 samequantum  7      -0     -> 1
! samq1518 samequantum  7      -0E+3  -> 0
! samq1519 samequantum  7       0E-3  -> 0
! samq1520 samequantum  7       0     -> 1
! samq1521 samequantum  7       0E+3  -> 0
! samq1522 samequantum  7       7E-3  -> 0
! samq1523 samequantum  7       7     -> 1
! samq1524 samequantum  7       7E+3  -> 0
! samq1525 samequantum  7       sNaN  -> 0
! 
! samq1610 samequantum  7E+3    -Inf   -> 0
! samq1611 samequantum  7E+3     Inf   -> 0
! samq1612 samequantum  7E+3     NaN   -> 0
! samq1613 samequantum  7E+3    -7E+3  -> 1
! samq1614 samequantum  7E+3    -7     -> 0
! samq1615 samequantum  7E+3    -7E-3  -> 0
! samq1616 samequantum  7E+3    -0E-3  -> 0
! samq1617 samequantum  7E+3    -0     -> 0
! samq1618 samequantum  7E+3    -0E+3  -> 1
! samq1619 samequantum  7E+3     0E-3  -> 0
! samq1620 samequantum  7E+3     0     -> 0
! samq1621 samequantum  7E+3     0E+3  -> 1
! samq1622 samequantum  7E+3     7E-3  -> 0
! samq1623 samequantum  7E+3     7     -> 0
! samq1624 samequantum  7E+3     7E+3  -> 1
! samq1625 samequantum  7E+3     sNaN  -> 0
! 
! samq1710 samequantum  sNaN    -Inf   -> 0
! samq1711 samequantum  sNaN     Inf   -> 0
! samq1712 samequantum  sNaN     NaN   -> 1
! samq1713 samequantum  sNaN    -7E+3  -> 0
! samq1714 samequantum  sNaN    -7     -> 0
! samq1715 samequantum  sNaN    -7E-3  -> 0
! samq1716 samequantum  sNaN    -0E-3  -> 0
! samq1717 samequantum  sNaN    -0     -> 0
! samq1718 samequantum  sNaN    -0E+3  -> 0
! samq1719 samequantum  sNaN     0E-3  -> 0
! samq1720 samequantum  sNaN     0     -> 0
! samq1721 samequantum  sNaN     0E+3  -> 0
! samq1722 samequantum  sNaN     7E-3  -> 0
! samq1723 samequantum  sNaN     7     -> 0
! samq1724 samequantum  sNaN     7E+3  -> 0
! samq1725 samequantum  sNaN     sNaN  -> 1
! -- noisy NaNs
! samq1730 samequantum  sNaN3    sNaN3 -> 1
! samq1731 samequantum  sNaN3    sNaN4 -> 1
! samq1732 samequantum   NaN3     NaN3 -> 1
! samq1733 samequantum   NaN3     NaN4 -> 1
! samq1734 samequantum  sNaN3     3    -> 0
! samq1735 samequantum   NaN3     3    -> 0
! samq1736 samequantum      4    sNaN4 -> 0
! samq1737 samequantum      3     NaN3 -> 0
! samq1738 samequantum    Inf    sNaN4 -> 0
! samq1739 samequantum   -Inf     NaN3 -> 0
! 
! 
! 

Index: squareroot.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/squareroot.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** squareroot.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- squareroot.decTest	21 Jun 2004 21:48:22 -0000	1.6
***************
*** 1,2958 ****
! ------------------------------------------------------------------------
! -- squareroot.decTest -- decimal square root                          --
! -- Copyright (c) IBM Corporation, 2003.  All rights reserved.         --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
[...5887 lines suppressed...]
! sqtx811 squareroot 10E-22   -> 3.16227766017E-11 Underflow Subnormal Inexact Rounded
! sqtx812 squareroot  1E-22   -> 1E-11 Subnormal   -- Exact Subnormal case
! 
! 
! -- special values
! maxexponent: 999
! minexponent: -999
! sqtx820 squareroot   Inf    -> Infinity
! sqtx821 squareroot  -Inf    -> NaN Invalid_operation
! sqtx822 squareroot   NaN    -> NaN
! sqtx823 squareroot  sNaN    -> NaN Invalid_operation
! -- propagating NaNs
! sqtx824 squareroot  sNaN123 ->  NaN123 Invalid_operation
! sqtx825 squareroot -sNaN321 -> -NaN321 Invalid_operation
! sqtx826 squareroot   NaN456 ->  NaN456
! sqtx827 squareroot  -NaN654 -> -NaN654
! sqtx828 squareroot   NaN1   ->  NaN1
! 
! -- Null test
! sqtx900 squareroot  # -> NaN Invalid_operation

Index: subtract.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/subtract.decTest,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** subtract.decTest	6 Feb 2004 16:56:03 -0000	1.5
--- subtract.decTest	21 Jun 2004 21:48:23 -0000	1.6
***************
*** 1,853 ****
! ------------------------------------------------------------------------
! -- subtract.decTest -- decimal subtraction                            --
! -- Copyright (c) IBM Corporation, 1981, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
[...1687 lines suppressed...]
! minexponent: -79
! subx1101 subtract  0 1.52444E-80 -> -1.524E-80 Inexact Rounded Subnormal Underflow
! subx1102 subtract  0 1.52445E-80 -> -1.524E-80 Inexact Rounded Subnormal Underflow
! subx1103 subtract  0 1.52446E-80 -> -1.524E-80 Inexact Rounded Subnormal Underflow
! subx1104 subtract  1.52444E-80 0 ->  1.524E-80 Inexact Rounded Subnormal Underflow
! subx1105 subtract  1.52445E-80 0 ->  1.524E-80 Inexact Rounded Subnormal Underflow
! subx1106 subtract  1.52446E-80 0 ->  1.524E-80 Inexact Rounded Subnormal Underflow
! 
! subx1111 subtract  1.2345678E-80  1.2345671E-80 ->  0E-83 Inexact Rounded Subnormal Underflow
! subx1112 subtract  1.2345678E-80  1.2345618E-80 ->  0E-83 Inexact Rounded Subnormal Underflow
! subx1113 subtract  1.2345678E-80  1.2345178E-80 ->  0E-83 Inexact Rounded Subnormal Underflow
! subx1114 subtract  1.2345678E-80  1.2341678E-80 ->  0E-83 Inexact Rounded Subnormal Underflow
! subx1115 subtract  1.2345678E-80  1.2315678E-80 ->  3E-83         Rounded Subnormal
! subx1116 subtract  1.2345678E-80  1.2145678E-80 ->  2.0E-82       Rounded Subnormal
! subx1117 subtract  1.2345678E-80  1.1345678E-80 ->  1.00E-81      Rounded Subnormal
! subx1118 subtract  1.2345678E-80  0.2345678E-80 ->  1.000E-80     Rounded Subnormal
! 
! -- Null tests
! subx9990 subtract 10  # -> NaN Invalid_operation
! subx9991 subtract  # 10 -> NaN Invalid_operation

Index: tointegral.decTest
===================================================================
RCS file: /cvsroot/python/python/nondist/sandbox/decimal/tests/tointegral.decTest,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** tointegral.decTest	6 Feb 2004 16:56:03 -0000	1.2
--- tointegral.decTest	21 Jun 2004 21:48:23 -0000	1.3
***************
*** 1,170 ****
! ------------------------------------------------------------------------
! -- tointegral.decTest -- round decimal to integral value              --
! -- Copyright (c) IBM Corporation, 2001, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.35
! 
! -- This set of tests tests the extended specification 'round-to-integral
! -- value' operation (from IEEE 854, later modified in 754r).
! -- All non-zero results are defined as being those from either copy or
! -- quantize, so those are assumed to have been tested.
! -- Note that 754r requires that Inexact not be set, and we similarly
! -- assume Rounded is not set.
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minExponent: -999
! 
! intx001 tointegral      0     ->  0
! intx002 tointegral      0.0   ->  0
! intx003 tointegral      0.1   ->  0
! intx004 tointegral      0.2   ->  0
! intx005 tointegral      0.3   ->  0
! intx006 tointegral      0.4   ->  0
! intx007 tointegral      0.5   ->  1
! intx008 tointegral      0.6   ->  1
! intx009 tointegral      0.7   ->  1
! intx010 tointegral      0.8   ->  1
! intx011 tointegral      0.9   ->  1
! intx012 tointegral      1     ->  1
! intx013 tointegral      1.0   ->  1
! intx014 tointegral      1.1   ->  1
! intx015 tointegral      1.2   ->  1
! intx016 tointegral      1.3   ->  1
! intx017 tointegral      1.4   ->  1
! intx018 tointegral      1.5   ->  2
! intx019 tointegral      1.6   ->  2
! intx020 tointegral      1.7   ->  2
! intx021 tointegral      1.8   ->  2
! intx022 tointegral      1.9   ->  2
! -- negatives
! intx031 tointegral     -0     -> -0
! intx032 tointegral     -0.0   -> -0
! intx033 tointegral     -0.1   -> -0
! intx034 tointegral     -0.2   -> -0
! intx035 tointegral     -0.3   -> -0
! intx036 tointegral     -0.4   -> -0
! intx037 tointegral     -0.5   -> -1
! intx038 tointegral     -0.6   -> -1
! intx039 tointegral     -0.7   -> -1
! intx040 tointegral     -0.8   -> -1
! intx041 tointegral     -0.9   -> -1
! intx042 tointegral     -1     -> -1
! intx043 tointegral     -1.0   -> -1
! intx044 tointegral     -1.1   -> -1
! intx045 tointegral     -1.2   -> -1
! intx046 tointegral     -1.3   -> -1
! intx047 tointegral     -1.4   -> -1
! intx048 tointegral     -1.5   -> -2
! intx049 tointegral     -1.6   -> -2
! intx050 tointegral     -1.7   -> -2
! intx051 tointegral     -1.8   -> -2
! intx052 tointegral     -1.9   -> -2
! -- next two would be NaN using quantize(x, 0)
! intx053 tointegral    10E+30  -> 1.0E+31
! intx054 tointegral   -10E+30  -> -1.0E+31
! 
! -- numbers around precision
! precision: 9
! intx060 tointegral '56267E-10'   -> '0'
! intx061 tointegral '56267E-5'    -> '1'
! intx062 tointegral '56267E-2'    -> '563'
! intx063 tointegral '56267E-1'    -> '5627'
! intx065 tointegral '56267E-0'    -> '56267'
! intx066 tointegral '56267E+0'    -> '56267'
! intx067 tointegral '56267E+1'    -> '5.6267E+5'
! intx068 tointegral '56267E+2'    -> '5.6267E+6'
! intx069 tointegral '56267E+3'    -> '5.6267E+7'
! intx070 tointegral '56267E+4'    -> '5.6267E+8'
! intx071 tointegral '56267E+5'    -> '5.6267E+9'
! intx072 tointegral '56267E+6'    -> '5.6267E+10'
! intx073 tointegral '1.23E+96'    -> '1.23E+96'
! intx074 tointegral '1.23E+384'   -> '1.23E+384'
! intx075 tointegral '1.23E+999'   -> '1.23E+999'
! 
! intx080 tointegral '-56267E-10'  -> '-0'
! intx081 tointegral '-56267E-5'   -> '-1'
! intx082 tointegral '-56267E-2'   -> '-563'
! intx083 tointegral '-56267E-1'   -> '-5627'
! intx085 tointegral '-56267E-0'   -> '-56267'
! intx086 tointegral '-56267E+0'   -> '-56267'
! intx087 tointegral '-56267E+1'   -> '-5.6267E+5'
! intx088 tointegral '-56267E+2'   -> '-5.6267E+6'
! intx089 tointegral '-56267E+3'   -> '-5.6267E+7'
! intx090 tointegral '-56267E+4'   -> '-5.6267E+8'
! intx091 tointegral '-56267E+5'   -> '-5.6267E+9'
! intx092 tointegral '-56267E+6'   -> '-5.6267E+10'
! intx093 tointegral '-1.23E+96'   -> '-1.23E+96'
! intx094 tointegral '-1.23E+384'  -> '-1.23E+384'
! intx095 tointegral '-1.23E+999'  -> '-1.23E+999'
! 
! -- specials and zeros
! intx120 tointegral 'Inf'       ->  Infinity
! intx121 tointegral '-Inf'      -> -Infinity
! intx122 tointegral   NaN       ->  NaN
! intx123 tointegral  sNaN       ->  NaN  Invalid_operation
! intx124 tointegral     0       ->  0
! intx125 tointegral    -0       -> -0
! intx126 tointegral     0.000   ->  0
! intx127 tointegral     0.00    ->  0
! intx128 tointegral     0.0     ->  0
! intx129 tointegral     0       ->  0
! intx130 tointegral     0E-3    ->  0
! intx131 tointegral     0E-2    ->  0
! intx132 tointegral     0E-1    ->  0
! intx133 tointegral     0E-0    ->  0
! intx134 tointegral     0E+1    ->  0E+1
! intx135 tointegral     0E+2    ->  0E+2
! intx136 tointegral     0E+3    ->  0E+3
! intx137 tointegral     0E+4    ->  0E+4
! intx138 tointegral     0E+5    ->  0E+5
! intx139 tointegral    -0.000   -> -0
! intx140 tointegral    -0.00    -> -0
! intx141 tointegral    -0.0     -> -0
! intx142 tointegral    -0       -> -0
! intx143 tointegral    -0E-3    -> -0
! intx144 tointegral    -0E-2    -> -0
! intx145 tointegral    -0E-1    -> -0
! intx146 tointegral    -0E-0    -> -0
! intx147 tointegral    -0E+1    -> -0E+1
! intx148 tointegral    -0E+2    -> -0E+2
! intx149 tointegral    -0E+3    -> -0E+3
! intx150 tointegral    -0E+4    -> -0E+4
! intx151 tointegral    -0E+5    -> -0E+5
! -- propagating NaNs
! intx152 tointegral   NaN808    ->  NaN808
! intx153 tointegral  sNaN080    ->  NaN80  Invalid_operation
! intx154 tointegral  -NaN808    -> -NaN808
! intx155 tointegral -sNaN080    -> -NaN80  Invalid_operation
! intx156 tointegral  -NaN       -> -NaN
! intx157 tointegral -sNaN       -> -NaN    Invalid_operation
! 
! -- examples
! rounding:    half_up
! precision:   9
! intx200 tointegral     2.1    -> 2
! intx201 tointegral   100      -> 100
! intx202 tointegral   100.0    -> 100
! intx203 tointegral   101.5    -> 102
! intx204 tointegral  -101.5    -> -102
! intx205 tointegral   10E+5    -> 1.0E+6
! intx206 tointegral  7.89E+77  -> 7.89E+77
! intx207 tointegral   -Inf     -> -Infinity
! 
--- 1,176 ----
! ------------------------------------------------------------------------
! -- tointegral.decTest -- round decimal to integral value              --
! -- Copyright (c) IBM Corporation, 2001, 2003.  All rights reserved.   --
! ------------------------------------------------------------------------
! -- Please see the document "General Decimal Arithmetic Testcases"     --
! -- at http://www2.hursley.ibm.com/decimal for the description of      --
! -- these testcases.                                                   --
! --                                                                    --
! -- These testcases are experimental ('beta' versions), and they       --
! -- may contain errors.  They are offered on an as-is basis.  In       --
! -- particular, achieving the same results as the tests here is not    --
! -- a guarantee that an implementation complies with any Standard      --
! -- or specification.  The tests are not exhaustive.                   --
! --                                                                    --
! -- Please send comments, suggestions, and corrections to the author:  --
! --   Mike Cowlishaw, IBM Fellow                                       --
! --   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
! --   mfc at uk.ibm.com                                                   --
! ------------------------------------------------------------------------
! version: 2.38
! 
! -- This set of tests tests the extended specification 'round-to-integral
! -- value' operation (from IEEE 854, later modified in 754r).
! -- All non-zero results are defined as being those from either copy or
! -- quantize, so those are assumed to have been tested.
! -- Note that 754r requires that Inexact not be set, and we similarly
! -- assume Rounded is not set.
! 
! extended:    1
! precision:   9
! rounding:    half_up
! maxExponent: 999
! minExponent: -999
! 
! intx001 tointegral      0     ->  0
! intx002 tointegral      0.0   ->  0
! intx003 tointegral      0.1   ->  0
! intx004 tointegral      0.2   ->  0
! intx005 tointegral      0.3   ->  0
! intx006 tointegral      0.4   ->  0
! intx007 tointegral      0.5   ->  1
! intx008 tointegral      0.6   ->  1
! intx009 tointegral      0.7   ->  1
! intx010 tointegral      0.8   ->  1
! intx011 tointegral      0.9   ->  1
! intx012 tointegral      1     ->  1
! intx013 tointegral      1.0   ->  1
! intx014 tointegral      1.1   ->  1
! intx015 tointegral      1.2   ->  1
! intx016 tointegral      1.3   ->  1
! intx017 tointegral      1.4   ->  1
! intx018 tointegral      1.5   ->  2
! intx019 tointegral      1.6   ->  2
! intx020 tointegral      1.7   ->  2
! intx021 tointegral      1.8   ->  2
! intx022 tointegral      1.9   ->  2
! -- negatives
! intx031 tointegral     -0     -> -0
! intx032 tointegral     -0.0   -> -0
! intx033 tointegral     -0.1   -> -0
! intx034 tointegral     -0.2   -> -0
! intx035 tointegral     -0.3   -> -0
! intx036 tointegral     -0.4   -> -0
! intx037 tointegral     -0.5   -> -1
! intx038 tointegral     -0.6   -> -1
! intx039 tointegral     -0.7   -> -1
! intx040 tointegral     -0.8   -> -1
! intx041 tointegral     -0.9   -> -1
! intx042 tointegral     -1     -> -1
! intx043 tointegral     -1.0   -> -1
! intx044 tointegral     -1.1   -> -1
! intx045 tointegral     -1.2   -> -1
! intx046 tointegral     -1.3   -> -1
! intx047 tointegral     -1.4   -> -1
! intx048 tointegral     -1.5   -> -2
! intx049 tointegral     -1.6   -> -2
! intx050 tointegral     -1.7   -> -2
! intx051 tointegral     -1.8   -> -2
! intx052 tointegral     -1.9   -> -2
! -- next two would be NaN using quantize(x, 0)
! intx053 tointegral    10E+30  -> 1.0E+31
! intx054 tointegral   -10E+30  -> -1.0E+31
! 
! -- numbers around precision
! precision: 9
! intx060 tointegral '56267E-10'   -> '0'
! intx061 tointegral '56267E-5'    -> '1'
! intx062 tointegral '56267E-2'    -> '563'
! intx063 tointegral '56267E-1'    -> '5627'
! intx065 tointegral '56267E-0'    -> '56267'
! intx066 tointegral '56267E+0'    -> '56267'
! intx067 tointegral '56267E+1'    -> '5.6267E+5'
! intx068 tointegral '56267E+2'    -> '5.6267E+6'
! intx069 tointegral '56267E+3'    -> '5.6267E+7'
! intx070 tointegral '56267E+4'    -> '5.6267E+8'
! intx071 tointegral '56267E+5'    -> '5.6267E+9'
! intx072 tointegral '56267E+6'    -> '5.6267E+10'
! intx073 tointegral '1.23E+96'    -> '1.23E+96'
! intx074 tointegral '1.23E+384'   -> '1.23E+384'
! intx075 tointegral '1.23E+999'   -> '1.23E+999'
! 
! intx080 tointegral '-56267E-10'  -> '-0'
! intx081 tointegral '-56267E-5'   -> '-1'
! intx082 tointegral '-56267E-2'   -> '-563'
! intx083 tointegral '-56267E-1'   -> '-5627'
! intx085 tointegral '-56267E-0'   -> '-56267'
! intx086 tointegral '-56267E+0'   -> '-56267'
! intx087 tointegral '-56267E+1'   -> '-5.6267E+5'
! intx088 tointegral '-56267E+2'   -> '-5.6267E+6'
! intx089 tointegral '-56267E+3'   -> '-5.6267E+7'
! intx090 tointegral '-56267E+4'   -> '-5.6267E+8'
! intx091 tointegral '-56267E+5'   -> '-5.6267E+9'
! intx092 tointegral '-56267E+6'   -> '-5.6267E+10'
! intx093 tointegral '-1.23E+96'   -> '-1.23E+96'
! intx094 tointegral '-1.23E+384'  -> '-1.23E+384'
! intx095 tointegral '-1.23E+999'  -> '-1.23E+999'
! 
! -- subnormal inputs
! intx100 tointegral        1E-999 -> 0
! intx101 tointegral      0.1E-999 -> 0
! intx102 tointegral     0.01E-999 -> 0
! intx103 tointegral        0E-999 -> 0
! 
! -- specials and zeros
! intx120 tointegral 'Inf'       ->  Infinity
! intx121 tointegral '-Inf'      -> -Infinity
! intx122 tointegral   NaN       ->  NaN
! intx123 tointegral  sNaN       ->  NaN  Invalid_operation
! intx124 tointegral     0       ->  0
! intx125 tointegral    -0       -> -0
! intx126 tointegral     0.000   ->  0
! intx127 tointegral     0.00    ->  0
! intx128 tointegral     0.0     ->  0
! intx129 tointegral     0       ->  0
! intx130 tointegral     0E-3    ->  0
! intx131 tointegral     0E-2    ->  0
! intx132 tointegral     0E-1    ->  0
! intx133 tointegral     0E-0    ->  0
! intx134 tointegral     0E+1    ->  0E+1
! intx135 tointegral     0E+2    ->  0E+2
! intx136 tointegral     0E+3    ->  0E+3
! intx137 tointegral     0E+4    ->  0E+4
! intx138 tointegral     0E+5    ->  0E+5
! intx139 tointegral    -0.000   -> -0
! intx140 tointegral    -0.00    -> -0
! intx141 tointegral    -0.0     -> -0
! intx142 tointegral    -0       -> -0
! intx143 tointegral    -0E-3    -> -0
! intx144 tointegral    -0E-2    -> -0
! intx145 tointegral    -0E-1    -> -0
! intx146 tointegral    -0E-0    -> -0
! intx147 tointegral    -0E+1    -> -0E+1
! intx148 tointegral    -0E+2    -> -0E+2
! intx149 tointegral    -0E+3    -> -0E+3
! intx150 tointegral    -0E+4    -> -0E+4
! intx151 tointegral    -0E+5    -> -0E+5
! -- propagating NaNs
! intx152 tointegral   NaN808    ->  NaN808
! intx153 tointegral  sNaN080    ->  NaN80  Invalid_operation
! intx154 tointegral  -NaN808    -> -NaN808
! intx155 tointegral -sNaN080    -> -NaN80  Invalid_operation
! intx156 tointegral  -NaN       -> -NaN
! intx157 tointegral -sNaN       -> -NaN    Invalid_operation
! 
! -- examples
! rounding:    half_up
! precision:   9
! intx200 tointegral     2.1    -> 2
! intx201 tointegral   100      -> 100
! intx202 tointegral   100.0    -> 100
! intx203 tointegral   101.5    -> 102
! intx204 tointegral  -101.5    -> -102
! intx205 tointegral   10E+5    -> 1.0E+6
! intx206 tointegral  7.89E+77  -> 7.89E+77
! intx207 tointegral   -Inf     -> -Infinity
! 




More information about the Python-checkins mailing list