From 1a4576068e4925ca13f85d709283d3ab786ddaa4 Mon Sep 17 00:00:00 2001 From: Gary Talent Date: Wed, 16 Mar 2022 03:19:45 -0500 Subject: [PATCH] [ox/std] Fix C++20 deprecation issue with Vector::iterator (synced from 179d311598b22655df9e39a23a2d6c488260eac4) --- src/ox/std/vector.hpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/ox/std/vector.hpp b/src/ox/std/vector.hpp index fd8f6c2d5..a9ba0a860 100644 --- a/src/ox/std/vector.hpp +++ b/src/ox/std/vector.hpp @@ -139,8 +139,7 @@ class Vector: detail::VectorAllocator { } } - constexpr typename std::iterator::difference_type - operator-(const iterator &other) const noexcept { + constexpr auto operator-(const iterator &other) const noexcept { if constexpr(reverse) { return m_offset + other.m_offset; } else {