Merge "Check bounds in offsetToPtr"