Repository navigation
Commit 9822fa7
committed
fix: keep short float IN lists consistent with = for signed zero
Short Float32/Float64 IN lists are kept as membership expressions, which
compare floats by bit pattern, so -0.0 did not match 0.0. Fall back to the
equality chain when the list contains a zero literal.1 parent 70f2ed0 commit 9822fa7
3 files changed
Lines changed: 48 additions & 13 deletions
File tree
- datafusion
- optimizer/src/simplify_expressions
- sqllogictest/test_files
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4961 | 4961 | | |
4962 | 4962 | | |
4963 | 4963 | | |
4964 | | - | |
4965 | | - | |
4966 | 4964 | | |
4967 | 4965 | | |
4968 | 4966 | | |
| |||
4987 | 4985 | | |
4988 | 4986 | | |
4989 | 4987 | | |
4990 | | - | |
| 4988 | + | |
4991 | 4989 | | |
4992 | 4990 | | |
4993 | 4991 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
| 11 | + | |
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| |||
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
44 | 54 | | |
45 | 55 | | |
46 | 56 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1147 | 1147 | | |
1148 | 1148 | | |
1149 | 1149 | | |
| 1150 | + | |
| 1151 | + | |
| 1152 | + | |
| 1153 | + | |
| 1154 | + | |
| 1155 | + | |
| 1156 | + | |
| 1157 | + | |
| 1158 | + | |
| 1159 | + | |
| 1160 | + | |
| 1161 | + | |
| 1162 | + | |
| 1163 | + | |
| 1164 | + | |
| 1165 | + | |
| 1166 | + | |
| 1167 | + | |
| 1168 | + | |
| 1169 | + | |
| 1170 | + | |
| 1171 | + | |
| 1172 | + | |
| 1173 | + | |
| 1174 | + | |
| 1175 | + | |
| 1176 | + | |
0 commit comments