I edited an answer here to make it more deadlock-safe:
Why can't I use the 'await' operator within the body of a lock statement?
Someone else has reverted my edit, saying that it changes the original too much and should be posted as a separate answer. I feel my edit is in keeping with the spirit of the original and makes no changes to the public API of SemaphoreLocker
.
Should my edit stand or should it be posted as a separate answer?