Commit a3164b0
committed
fabtests: fix complex fill cast
The previous implementation was trying to fill complex numbers with
multiple chars in the integ_alphabet to randomize the data. Unfortunately,
this resulted in many complex numbers becoming invalid numbers (NaN).
Because of that, the data validation check would fail as NaN != NaN
To fix this, when filling the data, set the real and imaginary parts as
a single char element so the individual part is valid and can be used
in the computation and check.
Because the implementation of complex types differs on unix and Windows
systems, this requires the addition of a new function that initializes
the individual components of the complex number instead of the number
as a whole.
This requires moving the long_double typedef into the osd.h headers to
help with the casting.
Signed-off-by: Alexia Ingerson <[email protected]>1 parent ce936d0 commit a3164b0
4 files changed
+14
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | | - | |
44 | 43 | | |
45 | 44 | | |
46 | 45 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
775 | 775 | | |
776 | 776 | | |
777 | 777 | | |
778 | | - | |
779 | | - | |
| 778 | + | |
| 779 | + | |
780 | 780 | | |
781 | 781 | | |
782 | 782 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
83 | 83 | | |
84 | 84 | | |
85 | 85 | | |
| 86 | + | |
| 87 | + | |
86 | 88 | | |
87 | 89 | | |
88 | 90 | | |
| |||
120 | 122 | | |
121 | 123 | | |
122 | 124 | | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
123 | 129 | | |
124 | 130 | | |
125 | 131 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
724 | 724 | | |
725 | 725 | | |
726 | 726 | | |
| 727 | + | |
727 | 728 | | |
728 | 729 | | |
729 | 730 | | |
| |||
790 | 791 | | |
791 | 792 | | |
792 | 793 | | |
| 794 | + | |
| 795 | + | |
| 796 | + | |
| 797 | + | |
| 798 | + | |
793 | 799 | | |
794 | 800 | | |
795 | 801 | | |
| |||
0 commit comments