From 00847ab558079f62e38764fd7ac3e2e1a11bc399 Mon Sep 17 00:00:00 2001 From: Mateusz Pusz Date: Wed, 16 Oct 2024 17:22:59 +0200 Subject: [PATCH] fix(tests): freestanding build fixed --- test/static/quantity_test.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/test/static/quantity_test.cpp b/test/static/quantity_test.cpp index 95349e45..74b91daf 100644 --- a/test/static/quantity_test.cpp +++ b/test/static/quantity_test.cpp @@ -24,10 +24,12 @@ #include #include #include -#include #include #include #include +#if MP_UNITS_HOSTED +#include +#endif #ifdef MP_UNITS_IMPORT_STD import std; #else @@ -794,6 +796,7 @@ static_assert( static_assert( is_of_type>); +#if MP_UNITS_HOSTED static_assert(is_same_v(isq::length(1 * m) / isq::time(1 * s))).in(J) + isq::energy(1 * kg * m2 / s2)), quantity>); @@ -806,6 +809,7 @@ static_assert(is_same_v(isq::length(1 * m) static_assert(is_same_v(isq::length(1 * m) / isq::time(1 * s))).in(J)), quantity>); +#endif static_assert(is_of_type(1. * m) + 1 * m, quantity>); static_assert(is_of_type<1 * m + child_quantity(1. * m), quantity>);