8000 serde_adaptor_helper SFINE support by injae · Pull Request #41 · injae/serdepp · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

serde_adaptor_helper SFINE support #41

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Oct 31, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions cppm.toml
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,8 @@
nlohmann_json = { version="3.9.1", link="public", optional=true}
RapidJSON = { version="1.1.1", link="public", optional=true}
benchmark = { version="1.5.2", optional=true}
#hiredis = "git"
#"redis++" = "1.3.2"
#simdjson = {version="0.9.7", link="public"}
#ryml = { version= "0.2.0", link="public", optional=true}
#sol2 = { version="3.2.2"}
Expand Down
2 changes: 1 addition & 1 deletion examples/struct_attribute.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ namespace serde::attribute {
}
};
}
constexpr static auto tttt = detail::tttt{};
[[maybe_unused]] constexpr static auto tttt = detail::tttt{};
}

struct test_{
Expand Down
8 changes: 4 additions & 4 deletions include/serdepp/serializer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ namespace serde
{
using namespace serde::meta;

template <class Adaptor> struct serde_adaptor_helper {
template <class Adaptor, typename=void> struct serde_adaptor_helper {
// for support optional type parse
inline constexpr static bool is_null(Adaptor& adaptor, std::string_view key);
// for support no_remain function
Expand Down Expand Up @@ -69,8 +69,8 @@ namespace serde

template<typename S, typename T, typename = void>
struct serde_adaptor {
static void from(S& s, std::string_view key, T& data);
static void into(S& s, std::string_view key, const T& data);
static void from(S& s, std::string_view key, T& data){}
static void into(S& s, std::string_view key, const T& data){}
};

namespace detail {
Expand Down Expand Up @@ -511,7 +511,7 @@ namespace serde
ENUM
};

template<typename Format>
template<typename Format, typename=void>
struct serde_type_checker {
static bool is_integer(Format& format);
static bool is_sequence(Format& format);
Expand Down
0