write out constexpr variable within object #315
-
Consider the following example: struct test_case {
static constexpr std::string_view info{ "information" };
static constexpr auto index{ 42 };
std::string value;
};
template<>
glz::meta<test_case> {
static constexpr auto value{ glz::object("information", test_case::info, "index", test_case::index, "value", &test_case::value) };
}; This actually compiles(to my best knowledge) but does not write constexpr variables to json. Is there a way to achieve this? |
Beta Was this translation helpful? Give feedback.
Answered by
stephenberry
Jun 6, 2023
Replies: 1 comment 1 reply
-
Thanks for asking. I've wanted this behavior as well, so I'll create an issue for it. |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
jbbjarnason
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks for asking. I've wanted this behavior as well, so I'll create an issue for it.