diff --git a/example/glide_computer.cpp b/example/glide_computer.cpp index 533002a1..4da86872 100644 --- a/example/glide_computer.cpp +++ b/example/glide_computer.cpp @@ -90,8 +90,6 @@ void print(const R& gliders) for (const auto& p : g.polar) { const auto ratio = glide_ratio(g.polar[0]).force_in(one); std::cout << MP_UNITS_STD_FMT::format(" * {::N[.4]} @ {::N[.1]} -> {::N[.1]} ({::N[.1]})\n", p.climb, p.v, ratio, - // TODO is it possible to make ADL work below (we need another set of trig - // functions for strong angle in a different namespace) si::asin(1 / ratio).force_in(si::degree)); } std::cout << "\n"; @@ -168,8 +166,6 @@ void example() const auto weather_conditions = get_weather_conditions(); const task t = {waypoints[0], waypoints[1], waypoints[0]}; const aircraft_tow tow = {400 * m, 1.6 * m / s}; - // TODO use C++20 date library when available - // set `start_time` to 11:00 am today const timestamp start_time(std::chrono::system_clock::now()); print(sfty); diff --git a/src/core/include/mp-units/bits/hacks.h b/src/core/include/mp-units/bits/hacks.h index 2dd10f84..5a0d3e11 100644 --- a/src/core/include/mp-units/bits/hacks.h +++ b/src/core/include/mp-units/bits/hacks.h @@ -87,14 +87,9 @@ #endif -// TODO revise the below when clang-18 is released -#if MP_UNITS_COMP_CLANG >= 18 && __cplusplus >= 202300L && !defined __cpp_explicit_this_parameter - -#define __cpp_explicit_this_parameter 202110L #endif - #if !defined __cpp_lib_ranges_to_container namespace std { diff --git a/src/core/include/mp-units/ext/type_traits.h b/src/core/include/mp-units/ext/type_traits.h index ce68be69..2058d3c8 100644 --- a/src/core/include/mp-units/ext/type_traits.h +++ b/src/core/include/mp-units/ext/type_traits.h @@ -88,9 +88,8 @@ void to_base_specialization_of(const volatile Type*); } // namespace detail template typename Type> -// inline constexpr bool // TODO: Replace with concept when it works with MSVC -concept is_derived_from_specialization_of = requires(T* t) { detail::to_base_specialization_of(t); }; - +inline constexpr bool is_derived_from_specialization_of = + requires(T* t) { detail::to_base_specialization_of(t); }; namespace detail { diff --git a/test/static/quantity_test.cpp b/test/static/quantity_test.cpp index 1489a4df..5cea40a5 100644 --- a/test/static/quantity_test.cpp +++ b/test/static/quantity_test.cpp @@ -406,9 +406,6 @@ static_assert((std::uint8_t{255}* m %= 257 * m).numerical_value_in(m) != [] { return ui %= 257; }()); -// TODO ICE -// (https://developercommunity2.visualstudio.com/t/ICE-on-a-constexpr-operator-in-mp-unit/1302907) -#ifndef MP_UNITS_COMP_MSVC // clang-17 with modules build on ignores disabling conversion warnings #if !(defined MP_UNITS_COMP_CLANG && MP_UNITS_COMP_CLANG < 18 && defined MP_UNITS_MODULES) // next two lines trigger conversions warnings @@ -418,7 +415,6 @@ static_assert((22 * m /= 3.33).numerical_value_in(m) == 6); static_assert((22 * m *= 33.33 * one).numerical_value_in(m) == 733); static_assert((22 * m /= 3.33 * one).numerical_value_in(m) == 6); #endif -#endif template typename Q> concept invalid_compound_assignments = requires() { @@ -847,8 +843,8 @@ static_assert(10 * isq::mechanical_energy[J] == 5 * isq::force[N] * (2 * isq::le static_assert(1 * si::si2019::speed_of_light_in_vacuum == 299'792'458 * isq::speed[m / s]); // Different named dimensions -template // TODO Use `Reference` when Clang supports it. -concept invalid_comparison = !requires { 2 * R1 == 2 * R2; } && !requires { 2 * R2 == 2 * R1; }; +template +inline constexpr bool invalid_comparison = !requires { 2 * R1 == 2 * R2; } && !requires { 2 * R2 == 2 * R1; }; static_assert(invalid_comparison); diff --git a/test/static/unit_test.cpp b/test/static/unit_test.cpp index 2d4a6092..25ef2ce2 100644 --- a/test/static/unit_test.cpp +++ b/test/static/unit_test.cpp @@ -210,7 +210,6 @@ static_assert(kilojoule.symbol == "kJ"); static_assert(is_of_type, si::kilo_>); static_assert(is_of_type, si::kilo_>); -// TODO Should the below be a scaled version of metre^2? static_assert(is_of_type>); // !!! static_assert(is_of_type>>); // !!!