Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

chenkovsky
Copy link

itertools.count is thread safe. we can use this to remove lock

@alexferl
Copy link
Owner

I vaguely remember reading about this when I was porting it and if I recall correctly, itertools doesn't guarantee thread safety and is only thread safe because of the GIL in the CPython implementation. Is the lock that slow that you require a lockless implementation like this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants