Use QLatin1String overload for QString::endsWith

GIT_SILENT
parent 4bb6be8f
......@@ -203,7 +203,7 @@ bool ClangCodeCompletionModel::shouldStartCompletion(KTextEditor::View* view, co
if (userInsertion && lastChar == QLatin1Char('-') && includePathCompletionRequired(view->document()->line(position.line()))) {
return true;
}
if (userInsertion && inserted.endsWith(QStringLiteral("::"))) {
if (userInsertion && inserted.endsWith(QLatin1String("::"))) {
return true;
}
......
......@@ -63,7 +63,7 @@ void CMakeParseJob::run(ThreadWeaver::JobPointer /*self*/, ThreadWeaver::Thread*
}
ReferencedTopDUContext parentCtx;
if (document().str().endsWith(QStringLiteral("CMakeLists.txt"))) {
if (document().str().endsWith(QLatin1String("CMakeLists.txt"))) {
IndexedString parentFile = parentCMakeFile(document());
if (QFile::exists(parentFile.toUrl().toLocalFile())) {
......
......@@ -1515,7 +1515,7 @@ void GitPlugin::registerRepositoryForCurrentBranchChanges(const QUrl& repository
void GitPlugin::fileChanged(const QString& file)
{
Q_ASSERT(file.endsWith(QStringLiteral("HEAD")));
Q_ASSERT(file.endsWith(QLatin1String("HEAD")));
//SMTH/.git/HEAD -> SMTH/
const QUrl fileUrl = Path(file).parent().parent().toUrl();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment