Skip to content

Commit 2c5237b

Browse files
committed
Mark PyComplex as ThreadSafe
1 parent cd42d04 commit 2c5237b

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

vm/src/obj/objcomplex.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ use super::objtype::PyClassRef;
77
use crate::function::OptionalArg;
88
use crate::pyhash;
99
use crate::pyobject::{
10-
IntoPyObject, PyClassImpl, PyContext, PyObjectRef, PyRef, PyResult, PyValue,
10+
IntoPyObject, PyClassImpl, PyContext, PyObjectRef, PyRef, PyResult, PyValue, ThreadSafe,
1111
};
1212
use crate::vm::VirtualMachine;
1313

@@ -19,6 +19,9 @@ use crate::vm::VirtualMachine;
1919
pub struct PyComplex {
2020
value: Complex64,
2121
}
22+
23+
impl ThreadSafe for PyComplex {}
24+
2225
type PyComplexRef = PyRef<PyComplex>;
2326

2427
impl PyValue for PyComplex {

0 commit comments

Comments
 (0)