diff options
| author | Ahmad Samir <a.samirh78@gmail.com> | 2020-10-08 20:46:51 +0200 | 
|---|---|---|
| committer | David Faure <faure@kde.org> | 2020-10-10 15:56:48 +0000 | 
| commit | bc620cca1f4154704744fcdeb4f706e0c54e46f8 (patch) | |
| tree | 447e15827005707271d519ab47501157a2fd03ef | |
| parent | 3d43fb00ac762a51259b8cb07466fc7a303f6e57 (diff) | |
| download | kconfig-bc620cca1f4154704744fcdeb4f706e0c54e46f8.tar.gz kconfig-bc620cca1f4154704744fcdeb4f706e0c54e46f8.tar.bz2 | |
Port QRegExp to QRegularExpression
| -rw-r--r-- | src/kconfig_compiler/KConfigSourceGenerator.cpp | 9 | 
1 files changed, 5 insertions, 4 deletions
| diff --git a/src/kconfig_compiler/KConfigSourceGenerator.cpp b/src/kconfig_compiler/KConfigSourceGenerator.cpp index bb2694b2..2a8cf7f3 100644 --- a/src/kconfig_compiler/KConfigSourceGenerator.cpp +++ b/src/kconfig_compiler/KConfigSourceGenerator.cpp @@ -14,6 +14,7 @@  #include "KConfigSourceGenerator.h"  #include "KConfigCommonStructs.h" +#include <QRegularExpression>  KConfigSourceGenerator::KConfigSourceGenerator(      const QString &inputFile, @@ -334,7 +335,7 @@ void KConfigSourceGenerator::createNormalEntry(const CfgEntry *entry, const QStr      }      if (!entry->parentGroup.isEmpty()) { -        stream() << "  " << itemVarStr << "->setGroup(cg" << QString(entry->group).remove(QRegExp(QStringLiteral("\\W"))) << ");\n"; +        stream() << "  " << itemVarStr << "->setGroup(cg" << QString(entry->group).remove(QRegularExpression(QStringLiteral("\\W"))) << ");\n";      }      stream() << "  addItem( " << itemVarStr; @@ -421,16 +422,16 @@ void KConfigSourceGenerator::handleCurrentGroupChange(const CfgEntry *entry)      mCurrentGroup = entry->group;      if (!entry->parentGroup.isEmpty()) { -        QString parentGroup = QString(entry->parentGroup).remove(QRegExp(QStringLiteral("\\W"))); +        QString parentGroup = QString(entry->parentGroup).remove(QRegularExpression(QStringLiteral("\\W")));          if (!mConfigGroupList.contains(parentGroup)) {              stream() << "  KConfigGroup cg" << parentGroup                       << "(this->config(), " << paramString(entry->parentGroup, parseResult.parameters) << ");\n";              mConfigGroupList << parentGroup;          } -        QString currentGroup = QString(mCurrentGroup).remove(QRegExp(QStringLiteral("\\W"))); +        QString currentGroup = QString(mCurrentGroup).remove(QRegularExpression(QStringLiteral("\\W")));          if (!mConfigGroupList.contains(currentGroup)) {              stream() << "  KConfigGroup cg" << currentGroup -                     << " = cg" << QString(entry->parentGroup).remove(QRegExp(QStringLiteral("\\W"))) +                     << " = cg" << QString(entry->parentGroup).remove(QRegularExpression(QStringLiteral("\\W")))                       << ".group(" << paramString(mCurrentGroup, parseResult.parameters) << ");\n";              mConfigGroupList << currentGroup;          } | 
