1#ifndef VEG_META_INT_DYN_HPP_GC385NKBS
2#define VEG_META_INT_DYN_HPP_GC385NKBS
7#include "proxsuite/linalg/veg/util/compare.hpp"
50 constexpr Dyn() =
default;
75#define VEG_OP(Op, Name, TypeName) \
76 VEG_TEMPLATE((typename R), \
77 requires(VEG_CONCEPT(index<R>)), \
78 VEG_NODISCARD VEG_INLINE constexpr auto \
81 const VEG_NOEXCEPT->typename _detail::binary_traits<Dyn, R>::TypeName \
83 return _detail::binary_traits<Dyn, R>::Name##_fn(*this, b); \
117#define VEG_CMP(Name, TypeName, Op) \
118 VEG_TEMPLATE((typename R), \
119 requires(VEG_CONCEPT(index<R>)), \
120 VEG_NODISCARD VEG_INLINE constexpr auto \
123 const VEG_NOEXCEPT->typename _detail::binary_traits<Dyn, R>::TypeName \
125 return _detail::binary_traits<Dyn, R>::cmp_##Name##_fn(*this, b); \
170#define VEG_OP(Name, TypeName, Op) \
171 using TypeName = Dyn; \
172 VEG_NODISCARD VEG_INLINE static constexpr auto Name##_fn(Dyn a, Dyn b) \
173 VEG_NOEXCEPT->TypeName \
175 return { isize(usize(isize(a)) Op usize(isize(b))) }; \
177 static_assert(true, "")
179#define VEG_CMP(Name, TypeName, Op) \
180 using TypeName = Boolean<maybe>; \
181 VEG_NODISCARD VEG_INLINE static constexpr auto Name##_fn(Dyn a, Dyn b) \
182 VEG_NOEXCEPT->TypeName \
184 return (isize(a) Op isize(b)); \
186 static_assert(true, "")
260inline namespace literals {
273 out.insert(out.size(),
"maybe[", 6);
275 out.insert(out.size(),
"]", 1);
284 out.insert(out.size(),
"Dyn[", 4);
286 out.insert(out.size(),
"]", 1);
#define VEG_OP(Op, Name, TypeName)
meta::constant< Ternary, Ternary::maybe > maybe_c
_detail::_meta::make_signed< usize >::Type isize
#define VEG_INTERNAL_ASSERT_PRECONDITION
constexpr Boolean()=default
VEG_NODISCARD VEG_INLINE constexpr friend auto operator!(Boolean arg) VEG_NOEXCEPT -> Boolean
constexpr Boolean() VEG_NOEXCEPT=default
VEG_NODISCARD VEG_INLINE constexpr auto operator-() const VEG_NOEXCEPT -> Dyn
VEG_TEMPLATE((typename R), requires(VEG_CONCEPT(index< R >) &&VEG_CONCEPT(index< typename _detail::binary_traits< Dyn, R >::Mod >)), VEG_NODISCARD VEG_INLINE constexpr auto operator%,(b, R)) const VEG_NOEXCEPT -> typename _detail::binary_traits< Dyn, R >::Mod
VEG_TEMPLATE((typename R), requires(VEG_CONCEPT(index< R >) &&VEG_CONCEPT(index< typename _detail::binary_traits< Dyn, R >::Div >)), VEG_NODISCARD VEG_INLINE constexpr auto operator/,(b, R)) const VEG_NOEXCEPT -> typename _detail::binary_traits< Dyn, R >::Div
VEG_NODISCARD VEG_INLINE constexpr auto operator+() const VEG_NOEXCEPT -> Dyn
constexpr Fix() VEG_NOEXCEPT=default
VEG_NODISCARD VEG_INLINE constexpr auto get() const noexcept -> T const &
static VEG_NODISCARD constexpr auto div_fn(Dyn a, Dyn b) VEG_NOEXCEPT -> Div
VEG_CMP(cmp_le, CmpLE,<=)
VEG_CMP(cmp_gt, CmpGT, >)
static VEG_NODISCARD constexpr auto mod_fn(Dyn a, Dyn b) VEG_NOEXCEPT -> Mod
VEG_CMP(cmp_eq, CmpEq,==)
VEG_CMP(cmp_ge, CmpGE, >=)
VEG_CMP(cmp_neq, CmpNEq, !=)
VEG_NODISCARD static VEG_INLINE constexpr auto div_fn(Dyn a, Fix< N >) VEG_NOEXCEPT -> Div
meta::if_t< N==0, void, Dyn > Mod
typename binary_traits< Fix< N >, Dyn >::Mul Mul
VEG_NODISCARD static VEG_INLINE constexpr auto mod_fn(Dyn a, Fix< N >) VEG_NOEXCEPT -> Mod
static VEG_INLINE constexpr auto mul_fn(Dyn a, Fix< N >) VEG_NOEXCEPT -> Mul
meta::if_t< N==0, void, Dyn > Div
VEG_NODISCARD constexpr static VEG_INLINE auto mul_fn(Fix< 0 >, Dyn) VEG_NOEXCEPT -> Mul
static void to_string(fmt::Buffer &out, Ref< Boolean< maybe > > val)
static void to_string(fmt::Buffer &out, Ref< Dyn > val)