The reaction of triflic anhydride activated carbonyl compounds with 5-phenylbarbituric acids in a mild, non-catalyzed one-step procedure yields unusual tricyclic pyrano[2,3-d]pyrimidines or oxazolo[3,2-c]pyrimidines containing an ADA hydrogen bond pattern. By subsequent functionalisation, other derivatives are accessible, including for instance a pyrimidine containing phenolphthalein analogue, thereby combining established chromophoric systems with a supramolecular recognition unit.