Remove use of 'boost/type_traits.h'
This commit is contained in:
parent
3d3c468ddb
commit
7995295038
@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
#include "yaml-cpp/node/detail/node.h"
|
#include "yaml-cpp/node/detail/node.h"
|
||||||
#include "yaml-cpp/node/detail/node_data.h"
|
#include "yaml-cpp/node/detail/node_data.h"
|
||||||
#include <boost/type_traits.hpp>
|
#include <type_traits>
|
||||||
|
|
||||||
namespace YAML {
|
namespace YAML {
|
||||||
namespace detail {
|
namespace detail {
|
||||||
@ -23,8 +23,8 @@ struct get_idx {
|
|||||||
|
|
||||||
template <typename Key>
|
template <typename Key>
|
||||||
struct get_idx<
|
struct get_idx<
|
||||||
Key, typename boost::enable_if_c<boost::is_unsigned<Key>::value &&
|
Key, typename std::enable_if<std::is_unsigned<Key>::value &&
|
||||||
!boost::is_same<Key, bool>::value>::type> {
|
!std::is_same<Key, bool>::value>::type> {
|
||||||
static node* get(const std::vector<node*>& sequence, const Key& key,
|
static node* get(const std::vector<node*>& sequence, const Key& key,
|
||||||
shared_memory_holder /* pMemory */) {
|
shared_memory_holder /* pMemory */) {
|
||||||
return key < sequence.size() ? sequence[key] : 0;
|
return key < sequence.size() ? sequence[key] : 0;
|
||||||
@ -41,7 +41,7 @@ struct get_idx<
|
|||||||
};
|
};
|
||||||
|
|
||||||
template <typename Key>
|
template <typename Key>
|
||||||
struct get_idx<Key, typename boost::enable_if<boost::is_signed<Key> >::type> {
|
struct get_idx<Key, typename std::enable_if<std::is_signed<Key>::value >::type> {
|
||||||
static node* get(const std::vector<node*>& sequence, const Key& key,
|
static node* get(const std::vector<node*>& sequence, const Key& key,
|
||||||
shared_memory_holder pMemory) {
|
shared_memory_holder pMemory) {
|
||||||
return key >= 0 ? get_idx<std::size_t>::get(
|
return key >= 0 ? get_idx<std::size_t>::get(
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user