Skip to content

Commit

Permalink
C4SortObject: Use std::iota instead of std::ranges::iota since libc++…
Browse files Browse the repository at this point in the history
… does not yet support the latter
  • Loading branch information
Fulgen301 committed Nov 11, 2023
1 parent b456647 commit a58d187
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/C4FindObject.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -776,7 +776,7 @@ void C4SortObject::SortObjects(std::vector<C4Object *> &result)
std::span positionsSpan{positions.get(), result.size()};

// Initialize position array
std::ranges::iota(positionsSpan, 0);
std::iota(positionsSpan.begin(), positionsSpan.end(), 0);
// Sort
std::ranges::stable_sort(positionsSpan, C4SortObjectSTLCache{*this, result});
// Save actual object pointers in array (hacky).
Expand Down

0 comments on commit a58d187

Please sign in to comment.