ref: e5784c0a7fe51aa70d64026ea7c3e7cf49fe634b
dir: /lib/thread/hookstd.myr/
use std use "mutex" pkg thread = ;; var memlck var netlck var envlck const __init__ = { memlck = mkmtx() netlck = mkmtx() envlck = mkmtx() std.__lockinit( \ &memlck castto(void#), \ &netlck castto(void#), \ &envlck castto(void#), \ {mtx; mtxlock(mtx castto(mutex#))}, \ {mtx; mtxunlock(mtx castto(mutex#))} \ ) }