pyo3 icon indicating copy to clipboard operation
pyo3 copied to clipboard

GIL-free references to Python data

Open davidhewitt opened this issue 3 years ago • 0 comments

In comment to Py<PyBytes>::as_bytes:


I think there's a few other immutable types like str and tuple which I guess can also have treatment like this where py is necessary for reading, but once read, the GIL can be released. Might be interesting to follow up this another time.

Originally posted by @davidhewitt in https://github.com/PyO3/pyo3/pull/2235#pullrequestreview-915041031

davidhewitt avatar Apr 05 '22 08:04 davidhewitt