[Review requested] AsyncLock

Without commenting on the rest of it, your toContinuation needs to lock as well, or it will fail when the buffer of continuations is reallocated.

(But also you can’t store continuations in an ever-growing array without running out of memory.)

P.S. Thread Sanitizer is your friend!

2 Likes