Windows' AcquireSRWLockExclusive 是递归的吗?

Is Windows' AcquireSRWLockExclusive recursive?

我需要使用读写锁,但我也想确保锁在读写模式下都是递归的,这样在同一个线程上使用它的调用函数不会锁定。

我在 MSDN 文档上找不到任何内容。也许它藏在某个地方而我没有找到它?

SRWLocks 不是递归的,来自 the docs:

An SRW lock is the size of a pointer. The advantage is that it is fast to update the lock state. The disadvantage is that very little state information can be stored, so SRW locks cannot be acquired recursively. In addition, a thread that owns an SRW lock in shared mode cannot upgrade its ownership of the lock to exclusive mode.