Skip to content

Commit ab8cc52

Browse files
JRRudy1davidhewitt
authored andcommitted
Updated Element impl for bf16 to call py_clone instead of clone.
1 parent db1a1a3 commit ab8cc52

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/dtype.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -867,7 +867,7 @@ unsafe impl Element for bf16 {
867867
.get_or_init(py, || {
868868
PyArrayDescr::new_bound(py, "bfloat16").expect("A package which provides a `bfloat16` data type for NumPy is required to use the `half::bf16` element type.").unbind()
869869
})
870-
.clone()
870+
.clone_ref(py)
871871
.into_bound(py)
872872
}
873873
}

0 commit comments

Comments
 (0)