4 ms·
Your second use case is actually already covered in Python, assuming you have some kind of sentinel value you can break on: for s in iter(network_service.rea
by hchasestevens 7y ago
Your second use case is actually already covered in Python, assuming you have some kind of sentinel value you can break on:
for s in iter(network_service.read, ''):
process(s)