···11+---
22+'moroutine': minor
33+---
44+55+Synchronous `try*` variants for shared locks
66+77+**New methods on `Mutex` and `RwLock`**:
88+99+```ts
1010+// Non-blocking, single-attempt acquisition.
1111+// Returns a disposable guard on success, `null` on contention.
1212+mutex.tryLock(); // MutexGuard | null
1313+rwlock.tryReadLock(); // ReadGuard | null
1414+rwlock.tryWriteLock(); // WriteGuard | null
1515+```
1616+1717+Each makes a single atomic CAS attempt — no waiting, no retry. Composes with `using` since `null` skips dispose registration:
1818+1919+```ts
2020+using guard = mu.tryLock();
2121+if (!guard) return; // held elsewhere, nothing to dispose
2222+// ...critical section; auto-unlock on scope exit
2323+```
+8
README.md
···310310// or manually:
311311await mu.lock();
312312mu.unlock();
313313+314314+// Non-blocking attempt — returns null if held elsewhere.
315315+using guard = mu.tryLock();
316316+if (!guard) return;
313317```
314318315319#### RwLock
···319323320324using guard = await rw.readLock(); // multiple readers OK
321325using guard = await rw.writeLock(); // exclusive access
326326+327327+// Non-blocking variants — return null if unavailable.
328328+using r = rw.tryReadLock(); // null if write-locked
329329+using w = rw.tryWriteLock(); // null if any lock is held
322330```
323331324332### Using with Workers