The following pattern: `(C2 << X) << C1` will usually be transformed into `(C2 << C1) << X`, essentially swapping `X` and `C1`. However, this should only be done when `C1` is an immediate constant, otherwise thiscan lead to both constants being swapped forever. This fixes #118798.