Makes atoindex work, with all safeguards.