You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I don't know if this is a bug or feature, but BOOST_PFR_FUNCTIONS_FOR requires structure members to have an std::hash specialization, but it doesn't itself provide one, so the following example fails to compile:
Uncommenting the hash specialization will make this code compile, but it's bothersome to do this for every type that just needs some comparison and print operations. Would it be possible to have a BOOST_PFR_FUNCTIONS_FOR version that doesn't try to generate a hash function? (Especially that it generates a hash_value function that is only compatible with boost containers, not an std::hash specialization that is a more compatible solution with C++11 or later.) Or at least make hash_fields compatible with hash_value?
The text was updated successfully, but these errors were encountered:
I don't know if this is a bug or feature, but
BOOST_PFR_FUNCTIONS_FOR
requires structure members to have anstd::hash
specialization, but it doesn't itself provide one, so the following example fails to compile:Godbolt
Uncommenting the hash specialization will make this code compile, but it's bothersome to do this for every type that just needs some comparison and print operations. Would it be possible to have a
BOOST_PFR_FUNCTIONS_FOR
version that doesn't try to generate a hash function? (Especially that it generates ahash_value
function that is only compatible with boost containers, not anstd::hash
specialization that is a more compatible solution with C++11 or later.) Or at least makehash_fields
compatible withhash_value
?The text was updated successfully, but these errors were encountered: