8. The equation $(a-1)(\sin 2 x+\cos x)+(a+1) \cdot(\sin x-\cos 2 x)=0$ (parameter $a<0$) has $\qquad$ solutions in the interval $(-\pi, \pi)$.
8,4
The original equation can be transformed into $\sin \left(\frac{x}{2}+\frac{\pi}{2}\right)\left[\cos \left(\frac{3 x}{2}-\frac{\pi}{4}\right)+\frac{a+1}{a-1} \sin \left(\frac{3 x}{2}-\frac{\pi}{4}\right)\right]=0$.
(1) The equation $\sin \left(\frac{x}{2}+\frac{\pi}{4}\right)=0$ has a solution $x=-\frac{\pi}{2}$ in $(-\pi, \pi)$.
(2) For the equation $\cos \left(\frac{3 x}{2}-\frac{\pi}{4}\right)+\frac{a+1}{a-1} \sin \left(\frac{3 x}{2}-\frac{\pi}{4}\right)=0$, when $a=-1$, it becomes $\cos \left(\frac{3 x}{2}-\frac{\pi}{4}\right)=0$, yielding $x=-\frac{5 \pi}{6}, -\frac{\pi}{6}, \frac{\pi}{2}$;
When $a \neq-1$, it can be transformed into $\tan \left(\frac{3 x}{2}-\frac{\pi}{4}\right)=\frac{1-a}{a+1}$.
Furthermore, when $a<0$ and $a \neq-1$, $\frac{a-1}{a+1} \in(-\infty,-1) \cup(1,+\infty)$. Since $y=\tan \left(\frac{3 x}{2}-\frac{\pi}{4}\right)$ has 3 periods in $(-\pi, \pi)$, from the graph, we can see that the equation (1) always has 3 solutions, and none of them is $-\frac{\pi}{2}$. Therefore, when $a<0$, the original equation has 4 solutions.