<div dir="ltr"><div>Being good users open-source of Qt, <a href="https://github.com/Mudlet/Mudlet">we're</a> looking into our compatibility early on to help report any issues and we're finding this compatibility code to be rather problematic from the developer experience point of view:</div><div><br></div><div>QMap<QString, QList<QPointF>> customLines;</div><div>QMap<QString, QColor> customLinesColor;</div><div>// ...<br></div><div><br></div><div>#if (QT_VERSION >= QT_VERSION_CHECK(5, 14, 0))<br>    auto customLineKeys = customLines.keys();<br>    QSet<QString> missingKeys{customLineKeys.begin(), customLineKeys.end()};<br>    if (!customLinesColor.isEmpty()) {<br>        auto customLinesColorKeys = customLinesColor.keys();<br>        QSet<QString> customLinesColorKeysSet{customLinesColorKeys.begin(), customLinesColorKeys.end()};<br>        missingKeys.subtract(customLinesColorKeysSet);<br>    }<br>#else<br>    QSet<QString> missingKeys{customLines.keys().toSet().subtract(customLinesColor.keys().toSet())};<br>#endif</div><div><br></div><div>Are we doing it wrong or is this a regression in Qt? (<a href="https://bugreports.qt.io/browse/QTBUG-83697">QTBUG-83697</a>)</div></div>