mirror of
https://git.wownero.com/wownero/onion-wownero-blockchain-explorer.git
synced 2024-08-15 00:33:12 +00:00
build on mac and windows
This commit is contained in:
parent
4b5c4da570
commit
4983786ed5
5 changed files with 39 additions and 22 deletions
|
@ -91,17 +91,32 @@ class lambda_t {
|
|||
std::function<std::string(node_renderer<N> renderer, const std::string&)> fun;
|
||||
};
|
||||
|
||||
template <class Key, class Value>
|
||||
struct map : public std::map<Key, Value>
|
||||
{
|
||||
map() {}
|
||||
map(const map<Key, Value>& rhs) : std::map<Key, Value>(rhs) {}
|
||||
map(const std::initializer_list<typename std::map<Key, Value>::value_type>& args) : std::map<Key, Value>(args) {}
|
||||
map& operator=(const map& rhs)
|
||||
{
|
||||
std::map<Key, Value>::clear();
|
||||
for (auto& i : rhs)
|
||||
std::map<Key, Value>::insert(i);
|
||||
return *this;
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
using node = boost::make_recursive_variant<
|
||||
std::nullptr_t, std::string, int, double, bool, uint64_t, int64_t, uint32_t,
|
||||
internal::lambda_t<boost::recursive_variant_>,
|
||||
std::shared_ptr<internal::object_t<boost::recursive_variant_>>,
|
||||
std::map<const std::string, boost::recursive_variant_>,
|
||||
internal::map<const std::string, boost::recursive_variant_>,
|
||||
std::vector<boost::recursive_variant_>>::type;
|
||||
using object = internal::object_t<node>;
|
||||
using lambda = internal::lambda_t<node>;
|
||||
using map = std::map<const std::string, node>;
|
||||
using map = internal::map<const std::string, node>;
|
||||
using array = std::vector<node>;
|
||||
|
||||
std::string render(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue