Use object instead of pointer