math/mpreduce.h: Missing include files.
[u/mdw/catacomb] / math / t / mpint
... / ...
CommitLineData
1# Test vectors for conversion between MP ints and C ints
2#
3# The tests look messy because I'm fighting with atoi here as well as the
4# integer conversion routines I'm trying to test.
5
6fromuint {
7 0 0;
8 1 1;
9 -5 0xfffffffb;
10 0x7ffff 0x7ffff;
11 0x80000 0x80000;
12 0xfffff 0xfffff;
13 0x7fffffff 0x7fffffff;
14 0x80000000 0x80000000; # Bastard torture test
15 0xffffffff 0xffffffff;
16}
17
18fromint {
19 0 0;
20 1 1;
21 -5 -5;
22 0x7ffff 0x7ffff;
23 0x80000 0x80000;
24 0xfffff 0xfffff;
25 0x7fffffff 0x7fffffff;
26 -0x80000000 -0x80000000; # Bastard torture test
27}
28
29touint {
30 0 0;
31 1 1;
32 -5 -5;
33 0x7ffff 0x7ffff;
34 0x80000 0x80000;
35 0xfffff 0xfffff;
36 0x7fffffff 0x7fffffff;
37 0x80000000 -0x80000000; # Bastard torture test
38 0xffffffff 0xffffffff;
39}
40
41toint {
42 0 0;
43 1 1;
44 -5 -5;
45 0x7ffff 0x7ffff;
46 0x80000 0x80000;
47 0xfffff 0xfffff;
48 0x7fffffff 0x7fffffff;
49 -0x80000000 -0x80000000; # Bastard torture test
50}