with halogen-containing compounds which may be formed in situ