Skip to content

<string>: char_traits specializations for "exotic" chars #5311

Open
@tiagomacarios

Description

@tiagomacarios

libc++ has removed the char_traits base template.

... it must be noted that the Standard only specifies specializations of char_traits for char, char8_t, char16_t, char32_t and wchar_t. However, before this patch, we would provide a base template that accepted anything, and as a result code like std::basic_string<long long> would compile but nobody knows what it really does. It basically compiles by accident.

Should the MSVC STL adopt the same changes? This would greatly help cross-platform developers. Louis also has a great point about correctness.

Xcode 16.3 release notes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementSomething can be improved

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions