Utils: Fix matching wildcards to full paths

Fixes: QTCREATORBUG-24792
Change-Id: I82b4edea6260b07e1bdff065b157a4cd044ec629
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
Christian Stenger
2020-10-16 13:38:57 +02:00
parent 9f6eb972b7
commit 6c5eaed92c
4 changed files with 75 additions and 2 deletions

View File

@@ -104,4 +104,11 @@ T makeUniquelyNumbered(const T &preferred, const Container &reserved)
QTCREATOR_UTILS_EXPORT QString formatElapsedTime(qint64 elapsed);
/* This function is only necessary if you need to match the wildcard expression against a
* string that might contain path separators - otherwise
* QRegularExpression::wildcardToRegularExpression() can be used.
* Working around QRegularExpression::wildcardToRegularExpression() taking native separators
* into account and handling them to disallow matching a wildcard characters.
*/
QTCREATOR_UTILS_EXPORT QString wildcardToRegularExpression(const QString &original);
} // namespace Utils