reimplemented in terms of Variable and Locked typeclasses