[autofix.ci] apply automated fixes

This commit is contained in:
autofix-ci[bot] 2024-11-22 03:34:31 +00:00 committed by GitHub
parent 3f49d92011
commit 482e696847
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -357,19 +357,19 @@ QString escapeAmps( QString const & str );
QString unescapeAmps( QString const & str );
//restrict scope to this very file.
namespace{
namespace {
// encoding mappings between QStringConverter::Encoding and QTextCodec::Encoding
const QMap< QStringConverter::Encoding, QTextCodec::Encoding > encodingMap = {
{ QStringConverter::Latin1, QTextCodec::Latin1 },
{ QStringConverter::Utf8, QTextCodec::Utf8 },
{ QStringConverter::Utf16, QTextCodec::Utf16 },
{ QStringConverter::Utf16LE , QTextCodec::Utf16LE },
{ QStringConverter::Utf16BE , QTextCodec::Utf16BE },
{ QStringConverter::Utf32LE , QTextCodec::Utf32LE },
{ QStringConverter::Utf32BE , QTextCodec::Utf32BE },
{ QStringConverter::Utf16LE, QTextCodec::Utf16LE },
{ QStringConverter::Utf16BE, QTextCodec::Utf16BE },
{ QStringConverter::Utf32LE, QTextCodec::Utf32LE },
{ QStringConverter::Utf32BE, QTextCodec::Utf32BE },
// others
};
}
} // namespace
QTextCodec::Encoding detectCodec( QByteArray & ba, char16_t expectedFirstCharacter = 0 );
QStringConverter::Encoding detectEncoding( QByteArray & ba, char16_t expectedFirstCharacter = 0 );