Commit 41d86538 authored by Philip Trettner's avatar Philip Trettner
Browse files

added some traits for fixed ints

parent 819f0f41
#pragma once
#include <typed-geometry/detail/scalar_traits.hh>
#include <typed-geometry/detail/utility.hh>
#include <typed-geometry/types/scalars/default.hh>
......@@ -14,6 +15,10 @@ using i128 = fixed_int<2>;
using i192 = fixed_int<3>;
using i256 = fixed_int<4>;
TG_IMPL_ADD_TRAIT(type_name_prefix, char const*, i128, "i128");
TG_IMPL_ADD_TRAIT(type_name_prefix, char const*, i192, "i192");
TG_IMPL_ADD_TRAIT(type_name_prefix, char const*, i256, "i256");
template <int words>
struct fixed_int
{
......
#pragma once
#include <typed-geometry/detail/scalar_traits.hh>
#include <typed-geometry/detail/utility.hh>
#include <typed-geometry/types/scalars/default.hh>
......@@ -14,6 +15,10 @@ using u128 = fixed_uint<2>;
using u192 = fixed_uint<3>;
using u256 = fixed_uint<4>;
TG_IMPL_ADD_TRAIT(type_name_prefix, char const*, u128, "u128");
TG_IMPL_ADD_TRAIT(type_name_prefix, char const*, u192, "u192");
TG_IMPL_ADD_TRAIT(type_name_prefix, char const*, u256, "u256");
template <int words>
struct fixed_uint
{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment