This commit is contained in:
parent
dc07f3d58b
commit
4754359a21
4
deps/ox/src/ox/std/vec.cpp
vendored
4
deps/ox/src/ox/std/vec.cpp
vendored
@ -6,15 +6,13 @@
|
|||||||
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
|
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <ox/std/defines.hpp>
|
|
||||||
|
|
||||||
#include "vec.hpp"
|
#include "vec.hpp"
|
||||||
|
|
||||||
namespace ox {
|
namespace ox {
|
||||||
|
|
||||||
static_assert([] {
|
static_assert([] {
|
||||||
Vec2 v(1, 2);
|
Vec2 v(1, 2);
|
||||||
return v.x == 1 && v.y == 2 && v.size() == 2;
|
return v.x == 1 && v.y == 2;
|
||||||
}());
|
}());
|
||||||
|
|
||||||
}
|
}
|
||||||
|
15
deps/ox/src/ox/std/vec.hpp
vendored
15
deps/ox/src/ox/std/vec.hpp
vendored
@ -12,13 +12,9 @@
|
|||||||
#include <imgui.h>
|
#include <imgui.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include <ox/model/def.hpp>
|
#include <ox/std/concepts.hpp>
|
||||||
#include <ox/std/assert.hpp>
|
|
||||||
#include <ox/std/bit.hpp>
|
|
||||||
#include <ox/std/def.hpp>
|
#include <ox/std/def.hpp>
|
||||||
#include <ox/std/error.hpp>
|
#include <ox/std/error.hpp>
|
||||||
#include <ox/std/iterator.hpp>
|
|
||||||
#include <ox/std/math.hpp>
|
|
||||||
#include <ox/std/types.hpp>
|
#include <ox/std/types.hpp>
|
||||||
|
|
||||||
namespace ox {
|
namespace ox {
|
||||||
@ -61,15 +57,6 @@ class Vec2 {
|
|||||||
return !operator==(v);
|
return !operator==(v);
|
||||||
}
|
}
|
||||||
|
|
||||||
explicit constexpr operator class Point() const noexcept;
|
|
||||||
|
|
||||||
explicit constexpr operator class Size() const noexcept;
|
|
||||||
|
|
||||||
[[nodiscard]]
|
|
||||||
constexpr std::size_t size() const noexcept {
|
|
||||||
return 2;
|
|
||||||
}
|
|
||||||
|
|
||||||
constexpr Vec2 operator+(float i) const noexcept {
|
constexpr Vec2 operator+(float i) const noexcept {
|
||||||
return {x + i, y + i};
|
return {x + i, y + i};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user