Approaches to the synthesis of thiazolo and thiazino pyridoacridines: elucidating the mechanism of thiobenzamide cyclisations