In rejecting both capitalism and the state, some libertarian socialists align themselves with anarchists in opposition to both capitalist representative democracy and to authoritarian forms of Marxism. Although anarchists and Marxists share an ultimate goal of a stateless society, anarchists criticise most Marxists for advocating a transitional phase under which the state is used to achieve this aim. Nonetheless, libertarian Marxist tendencies such as autonomism and council communism have historically been intertwined with the anarchist movement. Anarchist movements have come into conflict with both capitalist and Marxist forces, sometimes at the same time as in the Spanish Civil War, although as in that war Marxists themselves are often divided in support or opposition to anarchism. Other political persecutions under bureaucratic parties have resulted in a strong historical antagonism between anarchists and libertarian Marxists on the one hand and Leninists, Marxist–Leninists and their derivatives such as Maoists on the other. However, in recent history libertarian socialists have repeatedly formed temporary alliances with Marxist–Leninist groups in order to protest institutions they both reject.