Fix usage of enable_if with GCC 8
Seems like the trick with the three dots isn't working with GCC 8 anymore. So let's make it a default template parameter then. Not sure whether GCC 8 is here correct and whether this workaround causes further trouble.
This commit is contained in:
parent
8ef92cbf47
commit
a4435bbcf3
|
@ -12,23 +12,23 @@ namespace ConversionUtilities {
|
||||||
/// \cond
|
/// \cond
|
||||||
namespace Helper {
|
namespace Helper {
|
||||||
|
|
||||||
template <class StringType, Traits::EnableIf<std::is_class<StringType>>...> std::size_t computeTupleElementSize(const StringType *str)
|
template <class StringType, Traits::EnableIf<std::is_class<StringType>>* = nullptr> std::size_t computeTupleElementSize(const StringType *str)
|
||||||
{
|
{
|
||||||
return str->size();
|
return str->size();
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class StringType, Traits::EnableIf<std::is_class<StringType>>...> std::size_t computeTupleElementSize(const StringType &str)
|
template <class StringType, Traits::EnableIf<std::is_class<StringType>>* = nullptr> std::size_t computeTupleElementSize(const StringType &str)
|
||||||
{
|
{
|
||||||
return str.size();
|
return str.size();
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class StringType, class CharType, Traits::EnableIf<std::is_same<typename StringType::value_type, CharType>>...>
|
template <class StringType, class CharType, Traits::EnableIf<std::is_same<typename StringType::value_type, CharType>>* = nullptr>
|
||||||
std::size_t computeTupleElementSize(const CharType *str)
|
std::size_t computeTupleElementSize(const CharType *str)
|
||||||
{
|
{
|
||||||
return std::char_traits<CharType>::length(str);
|
return std::char_traits<CharType>::length(str);
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class StringType, class CharType, Traits::EnableIf<std::is_same<typename StringType::value_type, CharType>>...>
|
template <class StringType, class CharType, Traits::EnableIf<std::is_same<typename StringType::value_type, CharType>>* = nullptr>
|
||||||
constexpr std::size_t computeTupleElementSize(CharType)
|
constexpr std::size_t computeTupleElementSize(CharType)
|
||||||
{
|
{
|
||||||
return 1;
|
return 1;
|
||||||
|
@ -36,7 +36,7 @@ constexpr std::size_t computeTupleElementSize(CharType)
|
||||||
|
|
||||||
template <class StringType, typename IntegralType,
|
template <class StringType, typename IntegralType,
|
||||||
Traits::EnableIf<Traits::Not<std::is_same<typename StringType::value_type, IntegralType>>, std::is_integral<IntegralType>,
|
Traits::EnableIf<Traits::Not<std::is_same<typename StringType::value_type, IntegralType>>, std::is_integral<IntegralType>,
|
||||||
std::is_unsigned<IntegralType>>...>
|
std::is_unsigned<IntegralType>>* = nullptr>
|
||||||
std::size_t computeTupleElementSize(IntegralType number, typename StringType::value_type base = 10)
|
std::size_t computeTupleElementSize(IntegralType number, typename StringType::value_type base = 10)
|
||||||
{
|
{
|
||||||
std::size_t size = 0;
|
std::size_t size = 0;
|
||||||
|
@ -47,7 +47,7 @@ std::size_t computeTupleElementSize(IntegralType number, typename StringType::va
|
||||||
|
|
||||||
template <class StringType, typename IntegralType,
|
template <class StringType, typename IntegralType,
|
||||||
Traits::EnableIf<Traits::Not<std::is_same<typename StringType::value_type, IntegralType>>, std::is_integral<IntegralType>,
|
Traits::EnableIf<Traits::Not<std::is_same<typename StringType::value_type, IntegralType>>, std::is_integral<IntegralType>,
|
||||||
std::is_signed<IntegralType>>...>
|
std::is_signed<IntegralType>>* = nullptr>
|
||||||
std::size_t computeTupleElementSize(IntegralType number, typename StringType::value_type base = 10)
|
std::size_t computeTupleElementSize(IntegralType number, typename StringType::value_type base = 10)
|
||||||
{
|
{
|
||||||
std::size_t size = number < 0 ? 1 : 0;
|
std::size_t size = number < 0 ? 1 : 0;
|
||||||
|
@ -56,23 +56,23 @@ std::size_t computeTupleElementSize(IntegralType number, typename StringType::va
|
||||||
return size;
|
return size;
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class StringType, Traits::EnableIf<std::is_class<StringType>>...> void append(StringType &target, const StringType *str)
|
template <class StringType, Traits::EnableIf<std::is_class<StringType>>* = nullptr> void append(StringType &target, const StringType *str)
|
||||||
{
|
{
|
||||||
target.append(*str);
|
target.append(*str);
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class StringType, Traits::EnableIf<std::is_class<StringType>>...> void append(StringType &target, const StringType &str)
|
template <class StringType, Traits::EnableIf<std::is_class<StringType>>* = nullptr> void append(StringType &target, const StringType &str)
|
||||||
{
|
{
|
||||||
target.append(str);
|
target.append(str);
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class StringType, class CharType, Traits::EnableIf<std::is_same<typename StringType::value_type, CharType>>...>
|
template <class StringType, class CharType, Traits::EnableIf<std::is_same<typename StringType::value_type, CharType>>* = nullptr>
|
||||||
void append(StringType &target, const CharType *str)
|
void append(StringType &target, const CharType *str)
|
||||||
{
|
{
|
||||||
target.append(str);
|
target.append(str);
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class StringType, class CharType, Traits::EnableIf<std::is_same<typename StringType::value_type, CharType>>...>
|
template <class StringType, class CharType, Traits::EnableIf<std::is_same<typename StringType::value_type, CharType>>* = nullptr>
|
||||||
void append(StringType &target, CharType c)
|
void append(StringType &target, CharType c)
|
||||||
{
|
{
|
||||||
target += c;
|
target += c;
|
||||||
|
@ -80,7 +80,7 @@ void append(StringType &target, CharType c)
|
||||||
|
|
||||||
template <class StringType, typename IntegralType,
|
template <class StringType, typename IntegralType,
|
||||||
Traits::EnableIf<Traits::Not<std::is_same<typename StringType::value_type, IntegralType>>, std::is_integral<IntegralType>,
|
Traits::EnableIf<Traits::Not<std::is_same<typename StringType::value_type, IntegralType>>, std::is_integral<IntegralType>,
|
||||||
std::is_unsigned<IntegralType>>...>
|
std::is_unsigned<IntegralType>>* = nullptr>
|
||||||
void append(StringType &target, IntegralType number, typename StringType::value_type base = 10)
|
void append(StringType &target, IntegralType number, typename StringType::value_type base = 10)
|
||||||
{
|
{
|
||||||
const auto start = target.begin() + target.size();
|
const auto start = target.begin() + target.size();
|
||||||
|
@ -92,7 +92,7 @@ void append(StringType &target, IntegralType number, typename StringType::value_
|
||||||
|
|
||||||
template <class StringType, typename IntegralType,
|
template <class StringType, typename IntegralType,
|
||||||
Traits::EnableIf<Traits::Not<std::is_same<typename StringType::value_type, IntegralType>>, std::is_integral<IntegralType>,
|
Traits::EnableIf<Traits::Not<std::is_same<typename StringType::value_type, IntegralType>>, std::is_integral<IntegralType>,
|
||||||
std::is_signed<IntegralType>>...>
|
std::is_signed<IntegralType>>* = nullptr>
|
||||||
void append(StringType &target, IntegralType number, typename StringType::value_type base = 10)
|
void append(StringType &target, IntegralType number, typename StringType::value_type base = 10)
|
||||||
{
|
{
|
||||||
if (number < 0) {
|
if (number < 0) {
|
||||||
|
@ -168,7 +168,7 @@ template <class Tuple> constexpr auto operator%(const Tuple &lhs, const char *rh
|
||||||
/*!
|
/*!
|
||||||
* \brief Allows construction of string-tuples via %-operator, eg. string1 % "string2" % string3.
|
* \brief Allows construction of string-tuples via %-operator, eg. string1 % "string2" % string3.
|
||||||
*/
|
*/
|
||||||
template <class Tuple, typename IntegralType, Traits::EnableIf<std::is_integral<IntegralType>>...>
|
template <class Tuple, typename IntegralType, Traits::EnableIf<std::is_integral<IntegralType>>* = nullptr>
|
||||||
constexpr auto operator%(const Tuple &lhs, IntegralType rhs) -> decltype(std::tuple_cat(lhs, std::make_tuple(rhs)))
|
constexpr auto operator%(const Tuple &lhs, IntegralType rhs) -> decltype(std::tuple_cat(lhs, std::make_tuple(rhs)))
|
||||||
{
|
{
|
||||||
return std::tuple_cat(lhs, std::make_tuple(rhs));
|
return std::tuple_cat(lhs, std::make_tuple(rhs));
|
||||||
|
@ -223,7 +223,7 @@ constexpr auto operator%(char lhs, const std::string &rhs) -> decltype(std::make
|
||||||
* printVelocity("velocity: " % numberToString(velocityExample) % " km/h (" % numberToString(velocityExample / 3.6) + " m/s)"));
|
* printVelocity("velocity: " % numberToString(velocityExample) % " km/h (" % numberToString(velocityExample / 3.6) + " m/s)"));
|
||||||
* ```
|
* ```
|
||||||
*/
|
*/
|
||||||
template <class Tuple, Traits::EnableIf<Traits::IsSpecializationOf<Tuple, std::tuple>>...>
|
template <class Tuple, Traits::EnableIf<Traits::IsSpecializationOf<Tuple, std::tuple>>* = nullptr>
|
||||||
inline std::string operator+(const Tuple &lhs, const std::string &rhs)
|
inline std::string operator+(const Tuple &lhs, const std::string &rhs)
|
||||||
{
|
{
|
||||||
return tupleToString(std::tuple_cat(lhs, std::make_tuple(&rhs)));
|
return tupleToString(std::tuple_cat(lhs, std::make_tuple(&rhs)));
|
||||||
|
@ -238,7 +238,7 @@ inline std::string operator+(const Tuple &lhs, const std::string &rhs)
|
||||||
* printVelocity("velocity: " % numberToString(velocityExample) % " km/h (" % numberToString(velocityExample / 3.6) + " m/s)"));
|
* printVelocity("velocity: " % numberToString(velocityExample) % " km/h (" % numberToString(velocityExample / 3.6) + " m/s)"));
|
||||||
* ```
|
* ```
|
||||||
*/
|
*/
|
||||||
template <class Tuple, Traits::EnableIf<Traits::IsSpecializationOf<Tuple, std::tuple>>...>
|
template <class Tuple, Traits::EnableIf<Traits::IsSpecializationOf<Tuple, std::tuple>>* = nullptr>
|
||||||
inline std::string operator+(const Tuple &lhs, const char *rhs)
|
inline std::string operator+(const Tuple &lhs, const char *rhs)
|
||||||
{
|
{
|
||||||
return tupleToString(std::tuple_cat(lhs, std::make_tuple(rhs)));
|
return tupleToString(std::tuple_cat(lhs, std::make_tuple(rhs)));
|
||||||
|
@ -253,7 +253,7 @@ inline std::string operator+(const Tuple &lhs, const char *rhs)
|
||||||
* printVelocity("velocity: " % numberToString(velocityExample) % " km/h (" % numberToString(velocityExample / 3.6) + " m/s)"));
|
* printVelocity("velocity: " % numberToString(velocityExample) % " km/h (" % numberToString(velocityExample / 3.6) + " m/s)"));
|
||||||
* ```
|
* ```
|
||||||
*/
|
*/
|
||||||
template <class Tuple, typename IntegralType, Traits::EnableIf<Traits::IsSpecializationOf<Tuple, std::tuple>, std::is_integral<IntegralType>>...>
|
template <class Tuple, typename IntegralType, Traits::EnableIf<Traits::IsSpecializationOf<Tuple, std::tuple>, std::is_integral<IntegralType>>* = nullptr>
|
||||||
inline std::string operator+(const Tuple &lhs, IntegralType rhs)
|
inline std::string operator+(const Tuple &lhs, IntegralType rhs)
|
||||||
{
|
{
|
||||||
return tupleToString(std::tuple_cat(lhs, std::make_tuple(rhs)));
|
return tupleToString(std::tuple_cat(lhs, std::make_tuple(rhs)));
|
||||||
|
|
|
@ -287,7 +287,7 @@ template <typename CharType> constexpr CharType digitToChar(CharType digit)
|
||||||
* \sa stringToNumber()
|
* \sa stringToNumber()
|
||||||
*/
|
*/
|
||||||
template <typename IntegralType, class StringType = std::string,
|
template <typename IntegralType, class StringType = std::string,
|
||||||
Traits::EnableIf<std::is_integral<IntegralType>, Traits::Not<std::is_signed<IntegralType>>>...>
|
Traits::EnableIf<std::is_integral<IntegralType>, std::is_unsigned<IntegralType>>* = nullptr>
|
||||||
StringType numberToString(IntegralType number, typename StringType::value_type base = 10)
|
StringType numberToString(IntegralType number, typename StringType::value_type base = 10)
|
||||||
{
|
{
|
||||||
std::size_t resSize = 0;
|
std::size_t resSize = 0;
|
||||||
|
@ -308,7 +308,7 @@ StringType numberToString(IntegralType number, typename StringType::value_type b
|
||||||
* \tparam StringType The string type (should be an instantiation of the basic_string class template).
|
* \tparam StringType The string type (should be an instantiation of the basic_string class template).
|
||||||
* \sa stringToNumber()
|
* \sa stringToNumber()
|
||||||
*/
|
*/
|
||||||
template <typename IntegralType, class StringType = std::string, Traits::EnableIf<std::is_integral<IntegralType>, std::is_signed<IntegralType>>...>
|
template <typename IntegralType, class StringType = std::string, Traits::EnableIf<std::is_integral<IntegralType>, std::is_signed<IntegralType>>* = nullptr>
|
||||||
StringType numberToString(IntegralType number, typename StringType::value_type base = 10)
|
StringType numberToString(IntegralType number, typename StringType::value_type base = 10)
|
||||||
{
|
{
|
||||||
const bool negative = number < 0;
|
const bool negative = number < 0;
|
||||||
|
@ -340,7 +340,7 @@ StringType numberToString(IntegralType number, typename StringType::value_type b
|
||||||
* \a base and types).
|
* \a base and types).
|
||||||
* \sa stringToNumber(), bufferToNumber()
|
* \sa stringToNumber(), bufferToNumber()
|
||||||
*/
|
*/
|
||||||
template <typename FloatingType, class StringType = std::string, Traits::EnableIf<std::is_floating_point<FloatingType>>...>
|
template <typename FloatingType, class StringType = std::string, Traits::EnableIf<std::is_floating_point<FloatingType>>* = nullptr>
|
||||||
StringType numberToString(FloatingType number, typename StringType::value_type base = 10)
|
StringType numberToString(FloatingType number, typename StringType::value_type base = 10)
|
||||||
{
|
{
|
||||||
std::basic_stringstream<typename StringType::value_type> ss;
|
std::basic_stringstream<typename StringType::value_type> ss;
|
||||||
|
@ -377,7 +377,7 @@ template <typename CharType> CharType charToDigit(CharType character, CharType b
|
||||||
* \throws A ConversionException will be thrown if the provided \a string is not a valid number.
|
* \throws A ConversionException will be thrown if the provided \a string is not a valid number.
|
||||||
* \sa numberToString(), bufferToNumber()
|
* \sa numberToString(), bufferToNumber()
|
||||||
*/
|
*/
|
||||||
template <typename IntegralType, class StringType, Traits::EnableIf<std::is_integral<IntegralType>, Traits::Not<std::is_signed<IntegralType>>>...>
|
template <typename IntegralType, typename StringType, Traits::EnableIf<std::is_integral<IntegralType>, std::is_unsigned<IntegralType>>* = nullptr>
|
||||||
IntegralType stringToNumber(const StringType &string, typename StringType::value_type base = 10)
|
IntegralType stringToNumber(const StringType &string, typename StringType::value_type base = 10)
|
||||||
{
|
{
|
||||||
IntegralType result = 0;
|
IntegralType result = 0;
|
||||||
|
@ -398,7 +398,7 @@ IntegralType stringToNumber(const StringType &string, typename StringType::value
|
||||||
* \throws A ConversionException will be thrown if the provided \a string is not a valid number.
|
* \throws A ConversionException will be thrown if the provided \a string is not a valid number.
|
||||||
* \sa numberToString(), bufferToNumber()
|
* \sa numberToString(), bufferToNumber()
|
||||||
*/
|
*/
|
||||||
template <typename IntegralType, class StringType, Traits::EnableIf<std::is_integral<IntegralType>, std::is_signed<IntegralType>>...>
|
template <typename IntegralType, class StringType, Traits::EnableIf<std::is_integral<IntegralType>, std::is_signed<IntegralType>>* = nullptr>
|
||||||
IntegralType stringToNumber(const StringType &string, typename StringType::value_type base = 10)
|
IntegralType stringToNumber(const StringType &string, typename StringType::value_type base = 10)
|
||||||
{
|
{
|
||||||
auto i = string.begin();
|
auto i = string.begin();
|
||||||
|
@ -432,7 +432,7 @@ IntegralType stringToNumber(const StringType &string, typename StringType::value
|
||||||
* \a base and types).
|
* \a base and types).
|
||||||
* \sa numberToString(), bufferToNumber()
|
* \sa numberToString(), bufferToNumber()
|
||||||
*/
|
*/
|
||||||
template <typename FloatingType, class StringType, Traits::EnableIf<std::is_floating_point<FloatingType>>...>
|
template <typename FloatingType, class StringType, Traits::EnableIf<std::is_floating_point<FloatingType>>* = nullptr>
|
||||||
FloatingType stringToNumber(const StringType &string, typename StringType::value_type base = 10)
|
FloatingType stringToNumber(const StringType &string, typename StringType::value_type base = 10)
|
||||||
{
|
{
|
||||||
std::basic_stringstream<typename StringType::value_type> ss;
|
std::basic_stringstream<typename StringType::value_type> ss;
|
||||||
|
@ -452,7 +452,7 @@ FloatingType stringToNumber(const StringType &string, typename StringType::value
|
||||||
* \throws A ConversionException will be thrown if the provided \a string is not a valid number.
|
* \throws A ConversionException will be thrown if the provided \a string is not a valid number.
|
||||||
* \sa numberToString(), bufferToNumber()
|
* \sa numberToString(), bufferToNumber()
|
||||||
*/
|
*/
|
||||||
template <typename IntegralType, class CharType, Traits::EnableIf<std::is_integral<IntegralType>, Traits::Not<std::is_signed<IntegralType>>>...>
|
template <typename IntegralType, class CharType, Traits::EnableIf<std::is_integral<IntegralType>, std::is_unsigned<IntegralType>>* = nullptr>
|
||||||
IntegralType stringToNumber(const CharType *string, unsigned char base = 10)
|
IntegralType stringToNumber(const CharType *string, unsigned char base = 10)
|
||||||
{
|
{
|
||||||
IntegralType result = 0;
|
IntegralType result = 0;
|
||||||
|
@ -473,7 +473,7 @@ IntegralType stringToNumber(const CharType *string, unsigned char base = 10)
|
||||||
* \throws A ConversionException will be thrown if the provided \a string is not a valid number.
|
* \throws A ConversionException will be thrown if the provided \a string is not a valid number.
|
||||||
* \sa numberToString(), stringToNumber()
|
* \sa numberToString(), stringToNumber()
|
||||||
*/
|
*/
|
||||||
template <typename IntegralType, class CharType, Traits::EnableIf<std::is_integral<IntegralType>, Traits::Not<std::is_signed<IntegralType>>>...>
|
template <typename IntegralType, class CharType, Traits::EnableIf<std::is_integral<IntegralType>, std::is_unsigned<IntegralType>>* = nullptr>
|
||||||
IntegralType bufferToNumber(const CharType *string, std::size_t size, unsigned char base = 10)
|
IntegralType bufferToNumber(const CharType *string, std::size_t size, unsigned char base = 10)
|
||||||
{
|
{
|
||||||
IntegralType result = 0;
|
IntegralType result = 0;
|
||||||
|
@ -494,7 +494,7 @@ IntegralType bufferToNumber(const CharType *string, std::size_t size, unsigned c
|
||||||
* \throws A ConversionException will be thrown if the provided \a string is not a valid number.
|
* \throws A ConversionException will be thrown if the provided \a string is not a valid number.
|
||||||
* \sa numberToString(), bufferToNumber()
|
* \sa numberToString(), bufferToNumber()
|
||||||
*/
|
*/
|
||||||
template <typename IntegralType, class CharType, Traits::EnableIf<std::is_integral<IntegralType>, std::is_signed<IntegralType>>...>
|
template <typename IntegralType, class CharType, Traits::EnableIf<std::is_integral<IntegralType>, std::is_signed<IntegralType>>* = nullptr>
|
||||||
IntegralType stringToNumber(const CharType *string, unsigned char base = 10)
|
IntegralType stringToNumber(const CharType *string, unsigned char base = 10)
|
||||||
{
|
{
|
||||||
if (!*string) {
|
if (!*string) {
|
||||||
|
@ -527,7 +527,7 @@ IntegralType stringToNumber(const CharType *string, unsigned char base = 10)
|
||||||
* \throws A ConversionException will be thrown if the provided \a string is not a valid number.
|
* \throws A ConversionException will be thrown if the provided \a string is not a valid number.
|
||||||
* \sa numberToString(), stringToNumber()
|
* \sa numberToString(), stringToNumber()
|
||||||
*/
|
*/
|
||||||
template <typename IntegralType, class CharType, Traits::EnableIf<std::is_integral<IntegralType>, std::is_signed<IntegralType>>...>
|
template <typename IntegralType, class CharType, Traits::EnableIf<std::is_integral<IntegralType>, std::is_signed<IntegralType>>* = nullptr>
|
||||||
IntegralType bufferToNumber(const CharType *string, std::size_t size, unsigned char base = 10)
|
IntegralType bufferToNumber(const CharType *string, std::size_t size, unsigned char base = 10)
|
||||||
{
|
{
|
||||||
if (!size) {
|
if (!size) {
|
||||||
|
|
|
@ -120,7 +120,7 @@ constexpr auto color(Color foreground, ColorContext context, TextAttribute displ
|
||||||
|
|
||||||
template <typename TupleType,
|
template <typename TupleType,
|
||||||
Traits::EnableIfAny<std::is_same<TupleType, std::tuple<Color, Color, TextAttribute>>,
|
Traits::EnableIfAny<std::is_same<TupleType, std::tuple<Color, Color, TextAttribute>>,
|
||||||
std::is_same<TupleType, std::tuple<Color, ColorContext, TextAttribute>>>...>
|
std::is_same<TupleType, std::tuple<Color, ColorContext, TextAttribute>>>* = nullptr>
|
||||||
inline std::ostream &operator<<(std::ostream &stream, TupleType displayAttribute)
|
inline std::ostream &operator<<(std::ostream &stream, TupleType displayAttribute)
|
||||||
{
|
{
|
||||||
setStyle(stream, std::get<0>(displayAttribute), std::get<1>(displayAttribute), std::get<2>(displayAttribute));
|
setStyle(stream, std::get<0>(displayAttribute), std::get<1>(displayAttribute), std::get<2>(displayAttribute));
|
||||||
|
|
|
@ -192,7 +192,7 @@ template <typename T> AsHexNumber<T> asHexNumber(const T &value)
|
||||||
/*!
|
/*!
|
||||||
* \brief Allows printing pairs so key/values of maps/hashes can be asserted using CPPUNIT_ASSERT_EQUAL.
|
* \brief Allows printing pairs so key/values of maps/hashes can be asserted using CPPUNIT_ASSERT_EQUAL.
|
||||||
*/
|
*/
|
||||||
template <typename Pair, Traits::EnableIf<Traits::IsSpecializationOf<Pair, std::pair>>...>
|
template <typename Pair, Traits::EnableIf<Traits::IsSpecializationOf<Pair, std::pair>>* = nullptr>
|
||||||
inline std::ostream &operator<<(std::ostream &out, const Pair &pair)
|
inline std::ostream &operator<<(std::ostream &out, const Pair &pair)
|
||||||
{
|
{
|
||||||
return out << "key: " << pair.first << "; value: " << pair.second << '\n';
|
return out << "key: " << pair.first << "; value: " << pair.second << '\n';
|
||||||
|
@ -201,7 +201,7 @@ inline std::ostream &operator<<(std::ostream &out, const Pair &pair)
|
||||||
/*!
|
/*!
|
||||||
* \brief Allows printing iteratable objects so those can be asserted using CPPUNIT_ASSERT_EQUAL.
|
* \brief Allows printing iteratable objects so those can be asserted using CPPUNIT_ASSERT_EQUAL.
|
||||||
*/
|
*/
|
||||||
template <typename Iteratable, Traits::EnableIf<Traits::IsIteratable<Iteratable>, Traits::Not<Traits::IsString<Iteratable>>>...>
|
template <typename Iteratable, Traits::EnableIf<Traits::IsIteratable<Iteratable>, Traits::Not<Traits::IsString<Iteratable>>>* = nullptr>
|
||||||
inline std::ostream &operator<<(std::ostream &out, const Iteratable &iteratable)
|
inline std::ostream &operator<<(std::ostream &out, const Iteratable &iteratable)
|
||||||
{
|
{
|
||||||
out << '\n';
|
out << '\n';
|
||||||
|
|
Loading…
Reference in New Issue