Fix NSIndexSet compilation errors (#479).