From 9218c8f4ea863f13c8f379ffdd64fc74d323937c Mon Sep 17 00:00:00 2001 From: Anton Kudryavtsev Date: Tue, 22 Aug 2023 11:55:27 +0300 Subject: qcommandlineparser: replace QSL with QL1SV while touching code, use inline string, since there is only one user Change-Id: I6e89c24d8a37da090203e6eaf690d9094c5aa76a Reviewed-by: Thiago Macieira --- src/corelib/tools/qcommandlineparser.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/corelib/tools/qcommandlineparser.cpp') diff --git a/src/corelib/tools/qcommandlineparser.cpp b/src/corelib/tools/qcommandlineparser.cpp index c1581a27212..42babfbb24a 100644 --- a/src/corelib/tools/qcommandlineparser.cpp +++ b/src/corelib/tools/qcommandlineparser.cpp @@ -674,7 +674,6 @@ bool QCommandLineParserPrivate::parse(const QStringList &args) needsParsing = false; bool error = false; - const QString doubleDashString(QStringLiteral("--")); const QLatin1Char dashChar('-'); const QLatin1Char assignChar('='); @@ -698,7 +697,7 @@ bool QCommandLineParserPrivate::parse(const QStringList &args) if (forcePositional) { positionalArgumentList.append(argument); - } else if (argument.startsWith(doubleDashString)) { + } else if (argument.startsWith("--"_L1)) { if (argument.size() > 2) { QString optionName = argument.mid(2).section(assignChar, 0, 0); if (registerFoundOption(optionName)) { -- cgit v1.2.3