From 30b0a0c5dfff39bff7474fea037ad25e785c8f61 Mon Sep 17 00:00:00 2001 From: Mateusz Pusz Date: Mon, 12 Jun 2023 11:38:36 +0300 Subject: [PATCH] fix: `RepSafeConstructibleFrom` now works correctly with Arg being rvalue reference --- src/core/include/mp-units/quantity.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/core/include/mp-units/quantity.h b/src/core/include/mp-units/quantity.h index 6579a5c0..ff1dc9b1 100644 --- a/src/core/include/mp-units/quantity.h +++ b/src/core/include/mp-units/quantity.h @@ -47,9 +47,9 @@ template using quantity_like_type = quantity::reference, typename quantity_like_traits::rep>; template -concept RepSafeConstructibleFrom = - Unit> && std::constructible_from && - (treat_as_floating_point || (!treat_as_floating_point && is_rational(get_canonical_unit(U).mag))); +concept RepSafeConstructibleFrom = Unit> && std::constructible_from && + (treat_as_floating_point || (!treat_as_floating_point> && + is_rational(get_canonical_unit(U).mag))); template concept IntegralConversionFactor = Unit && Unit &&