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
The following information is odd anyway and as you'll see is easy to resolve on our side. Meaning I wasn't thinking any actions need to be done at all; but figured at least let you know about it.
First consider Microsoft has the ability to detect memory leaks with some Diagnostic Services via redefining the new operator:
The reason for the difference is that MSVC is using the old compiler frontend (/permissive) in C++17 mode and the new one in C++20 mode (/permissive-).
In "permissive" mode, syntax errors in templates that aren't used (such as the above shared_count constructor that takes an allocator) do not cause compilation to fail, but in "permissive-" mode, they do.
Since the code is already passing arguments to new, the macro that passes file/line causes a syntax error.
The following information is odd anyway and as you'll see is easy to resolve on our side. Meaning I wasn't thinking any actions need to be done at all; but figured at least let you know about it.
First consider Microsoft has the ability to detect memory leaks with some Diagnostic Services via redefining the
new
operator:With C++17 this isn't a problem as you can see with this online link: https://godbolt.org/z/nx35hhY9r
(note: Compiler Explorer doesn't install with MFC/ATL but those defines should give similar effect).
It builds. But if you change the setting to build as C++20 (or later) it fails to compile; here is an online link: https://godbolt.org/z/M3ba6r48h
I, myself, am using
boost
1.81.0 where I am noticing this issue.Hope that helps!
The text was updated successfully, but these errors were encountered: