Implements simple cases of borrow checking.