The C toupper function is locale-dependent. Given the right locale
(Türkiye, e.g.), toupper(i) is either
- İ (LATIN CAPITAL LETTER I WITH DOT ABOVE; if representable) or
- i (unchanged; if it isn't)
The latter is clearly wrong. The former might be what is wanted, but
since most locales these days are UTF-8, Í will be unlikely to be
representable in char.
So I conclude that what's intended here is that i gets mapped to I,
even in the Türkiye locale, so use the new QMiscUtils::toAsciiUpper()
instead of <ctype.h> toupper().
Fixes: QTBUG-109520
Pick-to: 6.5 6.4
Change-Id: I6fee2fb15c2facae79f1727455180567698fed80
Reviewed-by: Samuel Ghinet <samuel.ghinet@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>