Integrated one-flow synthesis of heterocyclic thioquinazolinones through serial microreactions with two organolithium intermediates.