One of the interesting aspects of Mill's work is that he takes the moral reasoning of the prophets seriously even though they were reasoning from theistic premises that he rejected. There are important lessons here for atheist philosophers. I've been working on abolitionism, which in the U.S. and Britain was overwhelmingly working from religious first premises. As an atheist, I have had to think hard about what to make of this. It seems to me that 19th century philosophers such as Mill and Hegel had more sophisticated views of how to understand religious arguments than contemporary atheist analytic philosophers. In analytic philosophy, if one starts off reasoning from a false premise, everything about the argument is wrong and it should be simply rejected out of hand. But for someone like Hegel, the externalization of moral requirements in the figure of God is a productive moment in the history of consciousness much in the way Mill outlined: it enabled people to distinguish the status quo from what was actually right and just, and supplied them with a critical perspective on current practice, insofar as theism enabled them to assume a "God's eye" perspective on conduct. That God as people imagine it does not literally exist no more undercuts the value of their moral reasoning than Mackie's critique of metaphysical moral realism undercuts critical moral reasoning today. (And even Mackie, after trashing moral realism, finds himself unable to avoid moralizing himself.) The critical moral point of view is essential and productive even if it is projected onto a fictional entity. What matters is the alternative perspective it affords, not its ontological status.
Smith explicitly internalizes this externalization: the "impartial and well-informed spectator" who judges our conduct is not God, but "the man within the breast"--our own conscience. From Hegel's point of view, this is another, more advanced stage in the history of consciousness. First we externalize a moral ideal, projecting it onto some imagined spirit supposedly independent of us--a god. But in our attempts to then live up to that ideal, to realize it in concrete social practices, we encounter "contradictions"--which is to say that how we imagined things would be when we attempt to follow some supposedly God-given moral principle is not how they actually turn out, but we find ourselves not able to satisfy all supposed moral requirements in our social order at the same time, and may end up making things worse for ourselves in certain respects in the attempt. This forces us to revise the original ideal. This process continues, and at some point, with the help of philosophy, we step back and realize what we are doing in this process! That is, that it is we who are projecting our own ideals onto a supposedly distinct god, rather than getting them handed down by some god who is imagined to be wholly external to us, and it is we who are continually revising our ideas of what God is telling us to do, in light of our own experiences attempting to follow his supposed commands.
This recognition of ourselves in what is supposedly wholly other now enables a further advance in critical thinking: now we can critically reflect on our own processes of moral thinking and consider whether those processes are systematically biased in problematic ways. Spinoza, Hobbes, Hume, and Smith are all important thinkers at this moment. Note that for Hume and Smith in particular, the mere fact that a belief is a projection does not automatically discredit it. We have to examine whether the underlying thought processes embody problematic biases. So we get things like the wonderful passages in The Theory of Moral Sentiments that criticize our sympathetic biases in favor of the rich and powerful, which also lead to unjust contempt and neglect of the poor and unfortunate.
At a further stage of philosophy, when we naturalize Hegel's insights as to how consciousness develops, from (i) externalization, to (ii) recognition of ourselves in that externalization, to (iii) self-conscious taking control over the whole process of continual revision by taking a critical perspective on how this works, and (iv) we subject this to empirical study (via, e.g., the discipline of psychology)--we get Dewey's pragmatism. I read Dewey as Hegel naturalized, and without an end to history or final answer to the normative questions we pose. The process of critical reflection, revision, testing in the world, and back again goes on forever, with no end in sight.