mirror of
https://github.com/mpusz/mp-units.git
synced 2025-08-07 06:04:27 +02:00
feat(example): validated_type
now properly registers as a scalar type
This commit is contained in:
@@ -25,6 +25,7 @@
|
||||
#include <gsl/gsl-lite.hpp>
|
||||
#include <mp-units/bits/external/hacks.h>
|
||||
#include <mp-units/bits/fmt.h>
|
||||
#include <mp-units/customization_points.h>
|
||||
#include <ostream>
|
||||
#include <utility>
|
||||
|
||||
@@ -100,6 +101,9 @@ public:
|
||||
= default;
|
||||
};
|
||||
|
||||
template<typename T, typename Validator>
|
||||
inline constexpr bool mp_units::is_scalar<validated_type<T, Validator>> = mp_units::is_scalar<T>;
|
||||
|
||||
|
||||
template<typename CharT, typename Traits, typename T, typename Validator>
|
||||
std::basic_ostream<CharT, Traits>& operator<<(std::basic_ostream<CharT, Traits>& os,
|
||||
|
Reference in New Issue
Block a user