Yet more work on eng::malloc
This commit is contained in:
@@ -6,7 +6,9 @@
|
||||
|
||||
namespace eng {
|
||||
template<class T>
|
||||
using deque = std::deque<T, eng::allocator<T>>;
|
||||
class deque : public std::deque<T, eng::allocator<T>>, public eng::opnew {
|
||||
using std::deque<T, eng::allocator<T>>::deque;
|
||||
};
|
||||
} // namespace eng
|
||||
|
||||
#endif // WRAP_DEQUE_HPP
|
||||
|
||||
@@ -6,7 +6,9 @@
|
||||
|
||||
namespace eng {
|
||||
template<class K, class V, class C=std::less<K>>
|
||||
using map = std::map<K, V, C, eng::allocator<std::pair<const K, V>>>;
|
||||
class map : public std::map<K, V, C, eng::allocator<std::pair<const K, V>>>, eng::opnew {
|
||||
using std::map<K, V, C, eng::allocator<std::pair<const K, V>>>::map;
|
||||
};
|
||||
} // namespace eng
|
||||
|
||||
#endif // WRAP_MAP_HPP
|
||||
|
||||
@@ -6,7 +6,9 @@
|
||||
|
||||
namespace eng {
|
||||
template<class K, class C=std::less<K>>
|
||||
using set = std::set<K, C, eng::allocator<K>>;
|
||||
class set : public std::set<K, C, eng::allocator<K>>, public eng::opnew {
|
||||
using std::set<K, C, eng::allocator<K>>::set;
|
||||
};
|
||||
} // namespace eng
|
||||
|
||||
#endif // WRAP_SET_HPP
|
||||
|
||||
@@ -2,11 +2,16 @@
|
||||
#define WRAP_SSTREAM_HPP
|
||||
|
||||
#include "eng-malloc.hpp"
|
||||
#include "wrap-string.hpp"
|
||||
#include <sstream>
|
||||
#include <string_view>
|
||||
|
||||
namespace eng {
|
||||
template<class C, class T=std::char_traits<C>>
|
||||
using basic_ostringstream = std::basic_ostringstream<C, T, eng::allocator<C>>;
|
||||
class basic_ostringstream : public std::basic_ostringstream<C, T, eng::allocator<C>>, public eng::opnew {
|
||||
using underlying = std::basic_ostringstream<C, T, eng::allocator<C>>;
|
||||
using underlying::basic_ostringstream;
|
||||
};
|
||||
using ostringstream = basic_ostringstream<char>;
|
||||
} // namespace eng
|
||||
|
||||
|
||||
@@ -6,7 +6,9 @@
|
||||
|
||||
namespace eng {
|
||||
template<class K, class V, class H=std::hash<K>, class E=std::equal_to<K>>
|
||||
using unordered_map = std::unordered_map<K, V, H, E, eng::allocator<std::pair<const K, V>>>;
|
||||
class unordered_map : public std::unordered_map<K, V, H, E, eng::allocator<std::pair<const K, V>>>, public eng::opnew {
|
||||
using std::unordered_map<K, V, H, E, eng::allocator<std::pair<const K, V>>>::unordered_map;
|
||||
};
|
||||
} // namespace eng
|
||||
|
||||
#endif // WRAP_UNORDERED_MAP_HPP
|
||||
|
||||
@@ -6,7 +6,9 @@
|
||||
|
||||
namespace eng {
|
||||
template<class K, class H=std::hash<K>, class E=std::equal_to<K>>
|
||||
using unordered_set = std::unordered_set<K, H, E, eng::allocator<K>>;
|
||||
class unordered_set : public std::unordered_set<K, H, E, eng::allocator<K>>, public eng::opnew {
|
||||
using std::unordered_set<K, H, E, eng::allocator<K>>::unordered_set;
|
||||
};
|
||||
} // namespace eng
|
||||
|
||||
#endif // WRAP_UNORDERED_SET_HPP
|
||||
|
||||
@@ -6,7 +6,9 @@
|
||||
|
||||
namespace eng {
|
||||
template<class T>
|
||||
using vector = std::vector<T, eng::allocator<T>>;
|
||||
class vector : public std::vector<T, eng::allocator<T>>, public eng::opnew {
|
||||
using std::vector<T, eng::allocator<T>>::vector;
|
||||
};
|
||||
} // namespace eng
|
||||
|
||||
#endif // WRAP_VECTOR_HPP
|
||||
|
||||
Reference in New Issue
Block a user