debugging index and ptr stuff