namespace ArduinoJson {
namespace Internals {

// A meta-function that returns true if T is an integral type.
template <typename T>
struct IsIntegral {
  static const bool value = IsSignedIntegral<T>::value ||
                            IsUnsignedIntegral<T>::value ||
                            IsSame<T, char>::value;
  // CAUTION: differs from std::is_integral as it doesn't include bool
};

template <typename T>
struct IsIntegral<const T> : IsIntegral<T> {};
}  // namespace Internals
}  // namespace ArduinoJson
