Skip to content

Commit 3cb1901

Browse files
authored
Merge pull request #522 from light-curve/clippy1.87
Fix clippy 1.87 warnings
2 parents 00ebbb1 + 1910994 commit 3cb1901

File tree

1 file changed

+9
-11
lines changed

1 file changed

+9
-11
lines changed

light-curve/src/dmdt.rs

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -656,17 +656,15 @@ macro_rules! dmdt_batches {
656656
if !slf.range.is_empty() {
657657
let rng = Self::child_rng(slf.rng.as_mut());
658658
// We know that it is None
659-
let _ = std::mem::replace(
660-
&mut *slf
661-
.worker_thread
662-
.write()
663-
.map_err(|_| ValueError(String::from("Error getting worker_thread")))?,
664-
Some(Self::run_worker_thread(
665-
&slf.dmdt_batches,
666-
&slf.lcs_order[slf.range.start..slf.range.end],
667-
rng,
668-
)),
669-
);
659+
let mut worker_thread = slf
660+
.worker_thread
661+
.write()
662+
.map_err(|_| ValueError(String::from("Error getting worker_thread")))?;
663+
*worker_thread = Some(Self::run_worker_thread(
664+
&slf.dmdt_batches,
665+
&slf.lcs_order[slf.range.start..slf.range.end],
666+
rng,
667+
));
670668
}
671669

672670
let py_array = array.into_pyarray(slf.py()).into_any();

0 commit comments

Comments
 (0)