Rewriting of collectors