The base template for std::char_traits is deprecated in Xcode 16.4 (after being too hastily removed in 16.3)

Ilmari Lauhakangas ilmari.lauhakangas at libreoffice.org
Mon May 19 05:28:08 UTC 2025


https://developer.apple.com/documentation/xcode-release-notes/xcode-16_3-release-notes#Deprecations
https://developer.apple.com/documentation/xcode-release-notes/xcode-16_4-release-notes#Resolved-Issues

"Fixed: The base template for std::char_traits is restored after being 
removed in Xcode 16.3; it is still deprecated and is going to be removed 
in a future release. Restoring the base template allows code that 
attempts to instantiate char_traits with types that are not provided by 
the Standard (for example, std::basic_string<long long> and similar) to 
still compile, giving it more time to transition.
 (149025504)"

Included at the end of this post are the non-standard uses I found in 
our code base.

Ilmari

include/o3tl/string_view.hxx:128:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:167:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:237:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:247:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:256:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:265:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:276:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:285:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:318:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:331:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:343:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:355:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:368:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:380:template <typename charT, typename 
traits = std::char_traits<charT>>
include/o3tl/string_view.hxx:436:template <typename charT, typename 
traits = std::char_traits<charT>>
sal/rtl/strtmpl.hxx:156:        return std::char_traits<T>::length(pStr);
sal/rtl/strtmpl.hxx:416:            cursor = 
std::char_traits<sal_Unicode>::find(cursor, end - cursor, *pSubStr);


More information about the LibreOffice mailing list