https://gcc.gnu.org/g:70452d24fa4bc6962f51232674ffdd6826723777

commit r14-11357-g70452d24fa4bc6962f51232674ffdd6826723777
Author: Jonathan Wakely <jwak...@redhat.com>
Date:   Mon Dec 16 09:45:40 2024 +0000

    libstdc++: Add missing character to __to_wstring_numeric map
    
    The mapping from char to wchar_t needs to handle 'i' and 'I' but those
    were absent from the table that is used for some non-ASCII encodings.
    
    libstdc++-v3/ChangeLog:
    
            * include/bits/basic_string.h (__to_wstring_numeric): Add 'i'
            and 'I' to mapping.
    
    (cherry picked from commit e1937cf33abded5c6ebbe4938a4a3e8cb3365176)

Diff:
---
 libstdc++-v3/include/bits/basic_string.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/libstdc++-v3/include/bits/basic_string.h 
b/libstdc++-v3/include/bits/basic_string.h
index 2794ec6419ac..abbe17cf4a15 100644
--- a/libstdc++-v3/include/bits/basic_string.h
+++ b/libstdc++-v3/include/bits/basic_string.h
@@ -4496,6 +4496,7 @@ _GLIBCXX_BEGIN_NAMESPACE_CXX11
        __wc['d'] = L'd';
        __wc['e'] = L'e';
        __wc['f'] = L'f';
+       __wc['i'] = L'i'; // for "inf"
        __wc['n'] = L'n'; // for "nan" and "inf"
        __wc['p'] = L'p'; // for hexfloats "0x1p1"
        __wc['x'] = L'x';
@@ -4505,6 +4506,7 @@ _GLIBCXX_BEGIN_NAMESPACE_CXX11
        __wc['D'] = L'D';
        __wc['E'] = L'E';
        __wc['F'] = L'F';
+       __wc['I'] = L'I';
        __wc['N'] = L'N';
        __wc['P'] = L'P';
        __wc['X'] = L'X';

Reply via email to