The builtin type autoLock: an object that keeps a lock and releases it
Put the object on the stack to make sure the destructor is called when
leaving the block. Otherwise it only happens when the garbage collector
finds the object unused, which may be much later.
autoLock %al = NEW(myLock)
# Do something that might crash
} # %al.Finish() calls myLock.end() here, always
NEW(lock) @public || Calls lock.begin().
status @public || Destructor: calls end() on the lock the object was created with.