summaryrefslogtreecommitdiffstats
path: root/src/corelib/tools/qregularexpression.cpp
diff options
context:
space:
mode:
authorAnton Kudryavtsev <antkudr@mail.ru>2017-03-29 07:10:46 +0300
committerAnton Kudryavtsev <antkudr@mail.ru>2017-03-30 20:31:59 +0000
commit5ec57560c0b497f9f48671dd200bb23d1f6eac35 (patch)
tree66903177b84d4fc481c8c4e689f47e79aa1a622c /src/corelib/tools/qregularexpression.cpp
parentce124d511917f95bd9193ec71f747f490ec982da (diff)
Prefer rvalue versions of toLatin() and toUtf8()
... to re-use existing buffers. Change-Id: I7c42529b8cd4400520a59e658ab76f4f8e965cd4 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/tools/qregularexpression.cpp')
-rw-r--r--src/corelib/tools/qregularexpression.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/tools/qregularexpression.cpp b/src/corelib/tools/qregularexpression.cpp
index 8366e01ee8..f1fac093b0 100644
--- a/src/corelib/tools/qregularexpression.cpp
+++ b/src/corelib/tools/qregularexpression.cpp
@@ -1674,7 +1674,7 @@ QString QRegularExpression::errorString() const
} while (errorStringLength < 0);
errorString.resize(errorStringLength);
- return QCoreApplication::translate("QRegularExpression", errorString.toLatin1().constData());
+ return QCoreApplication::translate("QRegularExpression", std::move(errorString).toLatin1().constData());
}
return QCoreApplication::translate("QRegularExpression", "no error");
}