Checking for edge cases in mem assert