Rename literal operator

Qt 6.4 introduced `QString operator""_s()` and the previous `""_qs` is
deprecated since Qt 6.8.
This commit is contained in:
Chocobo1
2023-06-18 02:02:02 +08:00
parent f6b58f36e2
commit e6d85a468b
141 changed files with 3610 additions and 3604 deletions

View File

@@ -189,7 +189,7 @@ bool RequestParser::parseRequestLine(const QString &line)
{
// [rfc7230] 3.1.1. Request Line
const QRegularExpression re(u"^([A-Z]+)\\s+(\\S+)\\s+HTTP\\/(\\d\\.\\d)$"_qs);
const QRegularExpression re(u"^([A-Z]+)\\s+(\\S+)\\s+HTTP\\/(\\d\\.\\d)$"_s);
const QRegularExpressionMatch match = re.match(line);
if (!match.hasMatch())
@@ -264,7 +264,7 @@ bool RequestParser::parsePostMessage(const QByteArray &data)
// [rfc2046] 5.1.1. Common Syntax
// find boundary delimiter
const QString boundaryFieldName = u"boundary="_qs;
const QString boundaryFieldName = u"boundary="_s;
const int idx = contentType.indexOf(boundaryFieldName);
if (idx < 0)
{
@@ -343,8 +343,8 @@ bool RequestParser::parseFormData(const QByteArray &data)
}
// pick data
const QString filename = u"filename"_qs;
const QString name = u"name"_qs;
const QString filename = u"filename"_s;
const QString name = u"name"_s;
if (headersMap.contains(filename))
{