先看 Dragonfly 里最反直觉的六行代码,src/core/intent_lock.h:20-26:
// Returns true if lock was acquired. In any case, the intent is recorded.
bool Acquire(Mode m) {
++cnt_[m];
if (cnt_[1 ^
先看 Dragonfly 里最反直觉的六行代码,src/core/intent_lock.h:20-26:
// Returns true if lock was acquired. In any case, the intent is recorded.
bool Acquire(Mode m) {
++cnt_[m];
if (cnt_[1 ^