‘Hostility to psychologism’, John McDowell writes, ‘is not hostility to the psychological. ‘Psychologism’ is an accusation. But it may be either of several.
The psychologism McDowell is master of detecting is, as he sometimes puts it, a form of scientism. It is a priori psychology where, at best, only substantive empirical psychology would do. It often represents itself as describing the way any thinker (or any empirical, or language-using one) must be; as describing requirements on being a thinker at all. But it misses viable alternatives. It is just speculation as to how we are.
McDowell sees Frege as his anti-psychologistic ally. Frege attacked misguided applications of psychology. What he attacked might certainly be called psychologism. But his target was rather different from McDowell's, which is better seen as the mis-derivation of substantive psychological results. Frege objected to mistaking the psychological for the logical. That would involve appealing to perhaps quite genuine psychological facts as deciding questions on which they did not (thus) bear. It would be to suppose our design as thinkers of a special sort to shape, not just our particular ways of thinking of things, or our capacities to see in the world what we can, but also that which we thus think about—to make some realm of non-psychological fact what it is.