https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104243
--- Comment #6 from Martin Liška <marxin at gcc dot gnu.org> ---
(In reply to A. Klitzing from comment #5)
> Created attachment 52294 [details]
> assembler output
>
> By the way... If idx is not initialized it will work, too.
>
> @@ -4,7 +4,7 @@
> int main(int argc, char** argv)
> {
> const QString pVersion = QStringLiteral("1.12.2");
> - int idx = 0;
> + int idx;
> const auto& version = QVersionNumber::fromString(pVersion, &idx);
>
> // #ifdef Q_CC_GNU
You were lucky in this case ;)
Anyway, upstream removed the pure attribute as we suggested:
https://codereview.qt-project.org/c/qt/qtbase/+/392357