Moving deallocation of functionIndices to ValueAxis destructor.