{{ message }}
Fix compatibility with older versions of VS - #4271
Merged
Merged
Conversation
vitaut
reviewed
Dec 21, 2024
Comment on lines
66
to
72
Contributor
There was a problem hiding this comment.
Let's move this to ostream.h where it is used.
Contributor
|
Also to clarify: |
Contributor
Author
To be precise, it has been supported since MSVC 19.12. Therefore, for versions from 19.00 to 19.12, use _MSVC_LANG instead. fmt has already declared that it does not support MSVC before version 19.00. Here are two version reference tables: _MSC_VER and _MSVC_STL_UPDATE. |
vitaut
reviewed
Dec 22, 2024
Comment on lines
+49
to
+53
| #ifdef _MSVC_LANG | ||
| # define FMT_CPLUSPLUS _MSVC_LANG | ||
| #else | ||
| # define FMT_CPLUSPLUS __cplusplus | ||
| #endif |
Contributor
There was a problem hiding this comment.
Could you also revert this unnecessary change to base.h?
vitaut
requested changes
Dec 22, 2024
vitaut
left a comment
Contributor
There was a problem hiding this comment.
Just one more minor comment, otherwise LGTM.
vitaut
approved these changes
Dec 23, 2024
Contributor
This was referenced Dec 25, 2024
This was referenced Mar 3, 2025
1 task
1 task
1 task
1 task
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

In the previous PR, I mentioned that there were no compatibility issues, but I was wrong. I confused the versions of VS and MSVC. _MSVC_STL_UPDATE appeared later than the VS version that fmt promised to support. This PR will fix this issue.