Comments (4)
OK, I assume this is a new C++20 feature - and one that breaks existing code given that u8"xyz"
was previously of type char[N]
? Is there an SD6 macro for this change - I can't see anything on the "official" SD6 page yet which seems not to have caught up with C++20?
Thanks, John.
from config.
Hey John, Casey Carter here from MSVC.
Is there an SD6 macro for this change
My understanding is that WG21 is no longer maintaining SD-6 now that the feature-test macros are being formally standardized and have moved into the working draft for C++20. There are two feature-test macros related to char8_t
: __cpp_char8_t
indicates compiler support for char8_t
as a type, and __cpp_lib_char8_t
indicates standard library support for e.g. u8string
, u8string_view
, char_traits<char8_t>
, etc.
And yes, u8"foo"
has type const char8_t[4]
in C++20 instead of const char[4]
as in C++17. It's a breaking change, albeit one that WG21 thinks is for the best, but purity of motivation doesn't make it any less problematic to support in libraries that need to be portable between C++17 and C++20.
Let me know if you have any questions or if there's anything I can do to ease the fix.
from config.
Many thanks for the clarification - the commit referenced above should hopefully fix this now.
from config.
Many thanks for the clarification - the commit referenced above should hopefully fix this now.
Looks right to me. Thanks for the quick response.
from config.
Related Issues (20)
- Macro misspellings in libcpp.hpp
- Missing BOOST_NO_CXX11_HDR_SCOPED_ALLOCATOR
- Autolink not working in VS2022 vs 17.0.6 HOT 2
- No BOOST_NO_CXX11_ALIGNOF HOT 4
- NVIDIA C++ compiler -cuda option triggers incompatible redefiniton of BOOST_COMPILER
- Support for IAR compiler HOT 1
- "Unknown compiler version" for Visual Studio 16 2019 HOT 2
- BOOST_HAS_INT128 not defined on clang-cl HOT 4
- Delete merged/stale branches HOT 1
- Configuration doesn't work correctly with clang on Linux HOT 5
- [MSVC][std:c++latest] Boost\libs\config run tests failed due to error C2666: 'boost_no_cxx11_unified_initialization_syntax::IdString::operator ==': overloaded functions have similar conversions HOT 3
- Missing define BOOST_NO_CXX11_NULLPTR on OSX with libstdc++ HOT 2
- New error for CLR projects which have no SFINAE HOT 2
- CMake - "lib" prefix bug in implibs of MSVC HOT 3
- BOOST_HAS_BUILTIN/BOOST_HAS_INCLUDE
- missing version macros
- missing header macros for C++23
- Outdated defect macros for Haiku HOT 1
- VS 2022 v17.10
- Missing features of C++/CLI seems to be flagged erroneously HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from config.