3 ms·
I assume this is a reference to the use of the GIL by a Python line such as “a,b = b,a” which swaps the value of a and b. As I understand it, this code invoke
by thamer 17y ago
I assume this is a reference to the use of the GIL by a Python line such as “a,b = b,a” which swaps the value of a and b.
As I understand it, this code invokes the GIL to ensure the atomicity of the operation. The code looks innocent though.
- kingkilr 17y agoUhh, every piece of code in Python "invokes the GIL". That's the point, it's a single global lock on the interpreter.