コード例 #1
0
def allocate_lock():
    return coros.semaphore(1, 9999)
コード例 #2
0
ファイル: event.py プロジェクト: woome/drivel
 def __init__(self, procid, publisher):
     self.events = {}
     self.procid = procid
     self.publisher = publisher
     self.pubsem = coros.semaphore(1)
コード例 #3
0
 def test_bounded_with_zero_limit(self):
     sem = coros.semaphore(0, 0)
     api.spawn(sem.acquire)
     sem.release()
コード例 #4
0
def allocate_lock():
    return coros.semaphore(1, 9999)