added pointer comparison