diff options
author | David Schulz <david.schulz@qt.io> | 2022-05-19 10:26:48 +0200 |
---|---|---|
committer | David Schulz <david.schulz@qt.io> | 2022-05-19 08:57:49 +0000 |
commit | f67a778d2e2f95c2102f5615cac841319e12ff6e (patch) | |
tree | 0e5793ec191f8de15984c4c10604bace909e2e40 | |
parent | 757b6554d8e4339dc290522bf4d3e65b664eeaa4 (diff) | |
download | qt-creator-f67a778d2e2f95c2102f5615cac841319e12ff6e.tar.gz |
Macro: fix saving macros
QMap::count returnes a size_type with Qt 6 in contrast to an int with
Qt 5. Convert this value always to an int to be backwards compatible.
Fixes: QTCREATORBUG-27543
Change-Id: Ibd37ede40e5eb4cd5e5172529455196242a97666
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
-rw-r--r-- | src/plugins/macros/macroevent.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/macros/macroevent.cpp b/src/plugins/macros/macroevent.cpp index 9b37298798..40dfd3de7f 100644 --- a/src/plugins/macros/macroevent.cpp +++ b/src/plugins/macros/macroevent.cpp @@ -75,7 +75,7 @@ void MacroEvent::load(QDataStream &stream) void MacroEvent::save(QDataStream &stream) const { stream << m_id.name(); - stream << m_values.count(); + stream << int(m_values.count()); for (auto i = m_values.cbegin(), end = m_values.cend(); i != end; ++i) stream << i.key() << i.value(); } |