-
-
Notifications
You must be signed in to change notification settings - Fork 6.8k
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
Implicit cast to std::string broken again with VS2019 16.5.0 #2006
Labels
kind: bug
release item: 🐛 bug fix
solution: proposed fix
a fix for the issue has been proposed and waits for confirmation
Milestone
Comments
Unfortunately appveyor 1 is still at 16.4. |
garethsb
added a commit
to garethsb/json
that referenced
this issue
Mar 24, 2020
Thanks @garethsb-sony ! |
With #2008 merged, can this issue be closed? |
From my side, yes, my issue is fixed. |
nlohmann
added
release item: 🐛 bug fix
solution: proposed fix
a fix for the issue has been proposed and waits for confirmation
labels
Apr 6, 2020
vslavik
added a commit
to vslavik/poedit
that referenced
this issue
May 10, 2020
Visual Studio 16.5 broke JSON for Modern C++'s implicit cast to std::string. Update bundled copy to current snapshot to fix. See nlohmann/json#2006
berezins
pushed a commit
to berezins/poedit
that referenced
this issue
Jun 9, 2020
Serhiy: - This is temporary cherry-pick from master to tetatetit:crowdin-new-oauth-api-xliff-clean PR - To be removed before final merge PR to master (to avoid conflict/duplication) - Necessary in order to remove some workaounds on JSON in this PR (which become needless with this commit) while to keep this PR buildable on Visual Studio Visual Studio 16.5 broke JSON for Modern C++'s implicit cast to std::string. Update bundled copy to current snapshot to fix. See nlohmann/json#2006
berezins
pushed a commit
to berezins/poedit
that referenced
this issue
Jun 9, 2020
Serhiy: - This is temporary cherry-pick from master to tetatetit:crowdin-new-oauth-api-xliff-clean PR - To be removed before final merge PR to master (to avoid conflict/duplication) - Necessary in order to remove some workaounds on JSON in this PR (which become needless with this commit) while to keep this PR buildable on Visual Studio Visual Studio 16.5 broke JSON for Modern C++'s implicit cast to std::string. Update bundled copy to current snapshot to fix. See nlohmann/json#2006
berezins
pushed a commit
to berezins/poedit
that referenced
this issue
Jun 9, 2020
Serhiy: - This is temporary cherry-pick from master to tetatetit:crowdin-new-oauth-api-xliff-clean PR - To be removed before final merge PR to master (to avoid conflict/duplication) - Necessary in order to remove some workaounds on JSON in this PR (which become needless with this commit) while to keep this PR buildable on Visual Studio Visual Studio 16.5 broke JSON for Modern C++'s implicit cast to std::string. Update bundled copy to current snapshot to fix. See nlohmann/json#2006
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
kind: bug
release item: 🐛 bug fix
solution: proposed fix
a fix for the issue has been proposed and waits for confirmation
The following program should compile.
With Visual Studio 2019 version 16.5.0, the above fails to compile. This is a recent release, but comes under "Microsoft Visual C++ 2019 / Build Tools 16.3.1+1def00d3d (and possibly later)".
The error message is:
develop
branch?I tried both a recent release and HEAD of
develop
.The same error message is reported when trying to compile test\src\unit-conversions.cpp.
In both cases the error can be resolved by removing the
#ifndef _MSC_VER
which ends up at https://github.com/nlohmann/json/blob/develop/single_include/nlohmann/json.hpp#L17468 (and the corresponding#endif
!). FWIW, in my testing with VS 2015 (for which that preprocessor condition was added), the code also compiles fine when it is removed.The compile-time and preprocessor conditions to enable implicit conversions have obviously been revisited many times over the life of nlohmann/json. A good place to start looking at the history is #188.
The text was updated successfully, but these errors were encountered: