Skip to content

Commit

Permalink
Work around broken macos span constructor
Browse files Browse the repository at this point in the history
  • Loading branch information
mtheall committed Jun 3, 2024
1 parent 03107a3 commit b3524da
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Sim/Arena/Arena.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -548,7 +548,7 @@ Arena::Arena(GameMode gameMode, const ArenaConfig& config, float tickRate) : _mu

bool isHoops = gameMode == GameMode::HOOPS;

auto toSpan = [](auto &val) { return std::span<const Vec, std::dynamic_extent> (std::begin (val), std::end (val)); };
auto toSpan = [](auto &val) { return std::span<const Vec, std::dynamic_extent> (&*std::begin (val), &*std::end (val)); };

std::span<const Vec> big = isHoops ? toSpan (LOCS_BIG_HOOPS) : toSpan (LOCS_BIG_SOCCAR);
std::span<const Vec> small = isHoops ? toSpan (LOCS_SMALL_HOOPS) : toSpan (LOCS_SMALL_SOCCAR);
Expand Down

0 comments on commit b3524da

Please sign in to comment.