Commit f709514
committed
Simplify descending complex comparator via operand negation
Implement `ExtendedComplexFPGreater` as `ExtendedComplexFPLess{}(-v1, -v2)`
instead of duplicating the comparison logic with operands swapped. Negation
preserves NaN-ness, so the NaN-based grouping (and its ordering to the end)
is unchanged while the finite-component comparison is reversed.1 parent 490c858 commit f709514
1 file changed
Lines changed: 3 additions & 30 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
107 | 107 | | |
108 | 108 | | |
109 | 109 | | |
110 | | - | |
111 | | - | |
112 | | - | |
| 110 | + | |
| 111 | + | |
113 | 112 | | |
114 | 113 | | |
115 | | - | |
116 | | - | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
121 | | - | |
122 | | - | |
123 | | - | |
124 | | - | |
125 | | - | |
126 | | - | |
127 | | - | |
128 | | - | |
129 | | - | |
130 | | - | |
131 | | - | |
132 | | - | |
133 | | - | |
134 | | - | |
135 | | - | |
136 | | - | |
137 | | - | |
138 | | - | |
139 | | - | |
140 | | - | |
141 | | - | |
| 114 | + | |
142 | 115 | | |
143 | 116 | | |
144 | 117 | | |
| |||
0 commit comments