Rewrote the comments in the libraries under 'includes' in English (excluding those inside folders)

This commit is contained in:
2026-07-29 23:34:36 +08:00
parent 3633be1995
commit a2cc28a6ab
54 changed files with 7091 additions and 899 deletions

View File

@@ -2,7 +2,6 @@ import t, c
import atom
@t.Object
class _spinlock:
locked: t.CVolatile | t.CInt
name: t.CArray[t.CChar, 32]
@@ -11,8 +10,7 @@ class _spinlock:
self.locked = 0
def lock(self):
while atom.__atomic_test_and_set(c.Addr(self.locked), atom.ATOMIC_ACQUIRE):
pass
while atom.__atomic_test_and_set(c.Addr(self.locked), atom.ATOMIC_ACQUIRE): pass
def unlock(self):
atom.__atomic_clear(c.Addr(self.locked), atom.ATOMIC_RELEASE)