Re: [Python-ideas] Thread-safe generators

2017-04-17 Thread Greg Ewing
Nick Coghlan wrote: but at the cost of changing the nature of the workload in a given thread, and hence messing with the working set of objects it has active. Does the working set of an individual thread matter to anything? Or even an individual process? As far as the virtual memory system is c

Re: [Python-ideas] Thread-safe generators

2017-04-17 Thread Jim Baker
This is a bad idea in the generator itself, as commented earlier by others here. >From a cross implementation perspective, in Jython, different threads can call next on a non running generator, *so long as they coordinate with each other external to any use of this generator*, and this works fine.