Clean up and document Index API.  Add index_free_full() and index_delete_full().