project-kyoku/include/core/vector.h

22 lines
367 B
C
Raw Normal View History

2021-12-29 09:59:18 -05:00
#pragma once
#include <utility>
namespace kku
{
2022-05-07 23:43:12 -04:00
/// Vector2
///
/// Meaning an element of a vector space in math.
/// Don't mistake for std::vector<T>
2021-12-29 09:59:18 -05:00
template <typename T>
using Vector2 = std::pair<T, T>;
template <typename T>
inline constexpr auto makeVector(T&& l, T&& r) -> Vector2<T>
{
return std::make_pair(std::forward<T>(l), std::forward<T>(r));
}
}