diff options
Diffstat (limited to 'docs/checks/README-auto-unexpected-qstringbuilder.md')
-rw-r--r-- | docs/checks/README-auto-unexpected-qstringbuilder.md | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/docs/checks/README-auto-unexpected-qstringbuilder.md b/docs/checks/README-auto-unexpected-qstringbuilder.md new file mode 100644 index 00000000..0c9e8143 --- /dev/null +++ b/docs/checks/README-auto-unexpected-qstringbuilder.md @@ -0,0 +1,16 @@ +# auto-unexpected-qstringbuilder + +Finds places where auto is deduced to be `QStringBuilder` instead of `QString`, which introduces crashes. +Also warns for lambdas returning `QStringBuilder`. + +#### Example + + #define QT_USE_QSTRINGBUILDER + #include <QtCore/QString> + (...) + const auto path = "hello " + QString::fromLatin1("world"); + qDebug() << path; // CRASH + +#### Fixits + + export CLAZY_FIXIT="fix-auto-unexpected-qstringbuilder" |