3 ms·
I think (maybe) they mean something like: x = Foo() thread1.do_something_to_foo(x) thread2.do_something_to_foo(x) wait_on_threads(thread1, thread
by UncleEntity 8y ago
I think (maybe) they mean something like:
x = Foo()
thread1.do_something_to_foo(x)
thread2.do_something_to_foo(x)
wait_on_threads(thread1, thread2) # however that works in python?
do_something_to_modified_foo(x)
- rcthompson 8y agoWouldn't that be thread safety? I thought memory safety was things like preventing access to uninitialized or freed memory. As far as I know there's no way to do such things in pure Python.