2
$Id: dtostre-06.c,v 1.1 2007/02/06 12:36:58 dmix Exp $
9
PROGMEM static const struct dtostre_s t[] = {
11
{ { .fl = 4.4444442 }, 7, 0, "4.4444442e+00" },
12
{ { .fl = 4.4444442 }, 6, 0, "4.444444e+00" },
13
{ { .fl = 4.4444442 }, 5, 0, "4.44444e+00" },
14
{ { .fl = 4.4444442 }, 4, 0, "4.4444e+00" },
15
{ { .fl = 4.4444442 }, 3, 0, "4.444e+00" },
16
{ { .fl = 4.4444442 }, 2, 0, "4.44e+00" },
17
{ { .fl = 4.4444442 }, 1, 0, "4.4e+00" },
18
{ { .fl = 4.4444442 }, 0, 0, "4e+00" },
20
{ { .fl = 6.6666665 }, 7, 0, "6.6666665e+00" },
21
{ { .fl = 6.6666665 }, 6, 0, "6.666667e+00" },
22
{ { .fl = 6.6666665 }, 5, 0, "6.66667e+00" },
23
{ { .fl = 6.6666665 }, 4, 0, "6.6667e+00" },
24
{ { .fl = 6.6666665 }, 3, 0, "6.667e+00" },
25
{ { .fl = 6.6666665 }, 2, 0, "6.67e+00" },
26
{ { .fl = 6.6666665 }, 1, 0, "6.7e+00" },
27
{ { .fl = 6.6666665 }, 0, 0, "7e+00" },
29
{ { .fl = 9.999999 }, 6, 0, "9.999999e+00" },
30
{ { .fl = 9.999999 }, 5, 0, "1.00000e+01" },
31
{ { .fl = 9.999999 }, 4, 0, "1.0000e+01" },
32
{ { .fl = 9.999999 }, 3, 0, "1.000e+01" },
33
{ { .fl = 9.999999 }, 2, 0, "1.00e+01" },
34
{ { .fl = 9.999999 }, 1, 0, "1.0e+01" },
35
{ { .fl = 9.999999 }, 0, 0, "1e+01" },
37
{ { .fl = 1.2341233 }, 7, 0, "1.2341233e+00" },
38
{ { .fl = 1.2341233 }, 6, 0, "1.234123e+00" },
39
{ { .fl = 1.2341233 }, 5, 0, "1.23412e+00" },
40
{ { .fl = 1.2341233 }, 4, 0, "1.2341e+00" },
41
{ { .fl = 1.2341233 }, 3, 0, "1.234e+00" },
42
{ { .fl = 1.2341233 }, 2, 0, "1.23e+00" },
43
{ { .fl = 1.2341233 }, 1, 0, "1.2e+00" },
44
{ { .fl = 1.2341233 }, 0, 0, "1e+00" },
46
{ { .fl = 5.6789565 }, 7, 0, "5.6789565e+00" },
47
{ { .fl = 5.6789565 }, 6, 0, "5.678957e+00" },
48
{ { .fl = 5.6789565 }, 5, 0, "5.67896e+00" },
49
{ { .fl = 5.6789565 }, 4, 0, "5.6790e+00" },
50
{ { .fl = 5.6789565 }, 3, 0, "5.679e+00" },
51
{ { .fl = 5.6789565 }, 2, 0, "5.68e+00" },
52
{ { .fl = 5.6789565 }, 1, 0, "5.7e+00" },
53
{ { .fl = 5.6789565 }, 0, 0, "6e+00" },
60
for (i= 0; (size_t)i != sizeof(t)/sizeof(t[0]); i++)
61
run_dtostre (t+i, i+1);