We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 98755a2 commit 677e8ceCopy full SHA for 677e8ce
include/geode/basic/algorithm.h
@@ -50,12 +50,13 @@ namespace geode
50
OPENGEODE_ASSERT( to_delete.size() == values.size(),
51
"[delete_vector_elements] Number of elements in the two vectors "
52
"should match" );
53
- index_t nb_removed_elements{ 0 };
54
- if( absl::c_find( to_delete, true ) == to_delete.end() )
+ const auto it = absl::c_find( to_delete, true );
+ if( it == to_delete.end() )
55
{
56
return 0;
57
}
58
- for( const auto i : Indices{ to_delete } )
+ index_t nb_removed_elements{ 0 };
59
+ for( const auto i : Range{ it - to_delete.begin(), to_delete.size() } )
60
61
if( to_delete[i] )
62
0 commit comments