Note: To follow naming conventions of scsh, the old with-lock is renamed to with-lock*. The syntactic sugar version is with-lock now.