(f)
return g
A decorator that takes a generator function and makes it thread-safe.
A decorator that takes a generator function and makes it thread-safe.
A decorator that takes a generator function and makes it thread - safe .
def threadsafe_generator(f):
	"""A decorator that takes a generator function and makes it thread-safe.
	"""
	def g(*a, **kw):
		return threadsafe_iter(f(*a, **kw))
	return g
def threadsafe_generator ( f ) : def g ( * a , * * kw ) : return threadsafe_iter ( f ( * a , * * kw ) ) return g