In chapter 6 of Di Francesco, they introduce the normal ordering $$ (AB)(w) = \oint \frac{ dz }{ 2\pi i (z-w) }A(z) B(w)\ . $$$$ (AB)(w) = \oint_w \frac{ dz }{ 2\pi i (z-w) }A(z) B(w)\ .\tag{6.130}$$
So far so good. But then starting eq (6.139) $$ \oint_w \frac{ dz }{ z-w }A(z)B(w) = \oint_{|z|>|w|} \frac{ dz }{ z-w }A(z)B(w)-\oint_{|z|<|w|} \frac{ dz }{ z-w }B(w)A(z) \quad (6.139) $$$$ \oint_w \frac{ dz }{ z-w }A(z)B(w) = \oint_{|z|>|w|} \frac{ dz }{ z-w }A(z)B(w)-\oint_{|z|<|w|} \frac{ dz }{ z-w }B(w)A(z) \tag{6.139} $$ and $$ A(z) = \sum_n (z-x)^{-n - h_A}A_n(x), \quad B(z) = \sum_m (w-x)^{-m - h_B}B_n(x) \ , \quad (6.140) $$$$ A(z) = \sum_n (z-x)^{-n - h_A}A_n(x), \quad B(z) = \sum_m (w-x)^{-m - h_B}B_n(x) \ , \tag{6.140} $$ they try to convert the integral into sum of modes, which confuses me a lot.
The expansion coefficients/modes $A_n(x), B_n(x)$ in eq (6.140) clearly depend on the intermediate $x$. Moreover, when treating the two integrals in (6.139), two different intermediate $x$'s are needed. That makes the final conclusion eq (6.144) mysterious, $$ (AB)_m = \sum_{n \le -h_A}A_n B_{m - n }+ \sum_{n > -h_A} B_{m-n}A_n, \quad (6.144) $$$$ (AB)_m = \sum_{n \le -h_A}A_n B_{m - n }+ \sum_{n > -h_A} B_{m-n}A_n, \tag{6.144} $$ since there the dependence on $x$ is removed some how: how are the $A_n$ and $B_n$ defined concretely?
(By making the $z$ contours to be $|z| = |w| \pm \epsilon$ and take the $\epsilon \to 0$ seems to indicate that the intermediate $x \to w$: but that will render the expansion $B(w) = \sum_m (w-x)^{-m - h_B}B_m(x)$ funny.)