We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f4ef3cc commit e0e2528Copy full SHA for e0e2528
encodings/alp/src/alp/mod.rs
@@ -164,13 +164,11 @@ pub trait ALPFloat: private::Sealed + Float + Display + 'static {
164
.collect();
165
166
if !patch_indices.is_empty() {
167
- if let Some(fill_value) =
168
- Self::first_non_patched_encoded_value(&encoded, &patch_indices)
169
- {
170
- for index in patch_indices.iter() {
171
- let index = *index as usize;
172
- encoded[index] = fill_value;
173
- }
+ let fill_value =
+ Self::first_non_patched_encoded_value(&encoded, &patch_indices).unwrap_or_default();
+ for index in patch_indices.iter() {
+ let index = *index as usize;
+ encoded[index] = fill_value;
174
}
175
176
0 commit comments