Consecutive [1,5]-sigmatropic and dissociation-recombination processes in rearrangements of 3-substituted 3-acyl-3H-indazoles to 1-acylindazoles