[libcxx-commits] [PATCH] D157058: [libc++] Remove generic char_traits implementation
Nikolas Klauser via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Wed Aug 16 18:15:54 PDT 2023
philnik added a comment.
In D157058#4593597 <https://reviews.llvm.org/D157058#4593597>, @glandium wrote:
> I'll be honest, this change is kind of annoying. The deprecation itself was added in clang 17, which is yet to be released. IOW, most code bases that are using the deprecated char_traits haven't even had the chance to see those deprecation warnings. And now they hard-fail to build with clang trunk...
This has been deprecated since LLVM 16: https://releases.llvm.org/16.0.0/projects/libcxx/docs/ReleaseNotes.html#id6.
In D157058#4593864 <https://reviews.llvm.org/D157058#4593864>, @glandium wrote:
> Also, uses of e.g. basic_string<unsigned char> do not show a deprecation warning with clang 17 at all, because the trigger ends up being in <string>, which is a system header (as mentioned in previous comments).
That's not great, but we can't do much about that. It would be great if clang could be improved, but we can't wait a decade to wait for deprecated features to be removed.
In D157058#4593865 <https://reviews.llvm.org/D157058#4593865>, @glandium wrote:
> Oh and this one is fun too: `error: implicit instantiation of undefined template 'std::char_traits<const char>'`
That seems like a good thing to me, since it's almost definitely erroneous. You can't correctly implement things like `assign` for a `const char`.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D157058/new/
https://reviews.llvm.org/D157058
More information about the libcxx-commits
mailing list