Skip to content
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

RapidJson causes C5054 on MSVC #821

Open
dpservis opened this issue May 18, 2024 · 1 comment
Open

RapidJson causes C5054 on MSVC #821

dpservis opened this issue May 18, 2024 · 1 comment

Comments

@dpservis
Copy link

Hello,

The embedded version of RapidJson causes C5054 warnings on MSVC with C++20. They have fixed it on their side using static casts. Is it possible to update the library in Cereal?

Thanks

Dimitris

@sldr
Copy link

sldr commented Sep 17, 2024

Workaround (surround any include giving you the problem):

#ifdef _WIN32
#pragma warning(push)
#pragma warning(disable: 5054) // Include\cereal\external\rapidjson\document.h does '|' with two different enum types
#endif
#include <cereal/archives/json.hpp>
#ifdef _WIN32
#pragma warning(pop)
#endif

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants