diff options
author | Kai Köhne <kai.koehne@qt.io> | 2022-01-04 14:52:03 +0100 |
---|---|---|
committer | Marc Mutz <marc.mutz@qt.io> | 2022-01-05 15:30:06 +0000 |
commit | a9084297f629423c64d571d7f7286d3c0e239247 (patch) | |
tree | 50a6312f33b506bba9a2caed5e5102a3f88b3457 /src/qdoc/clangcodeparser.cpp | |
parent | bd8827cd95552372a5aca78a21210a46bddadc36 (diff) | |
download | qttools-a9084297f629423c64d571d7f7286d3c0e239247.tar.gz |
designer: Fix MSVC warning about returning address of local variable or temporary
std::reverse_iterator::operator*() returns by reference while
QKeyValueIterator::operator*() returns by value, so MSVC is correct
when it warns about returning the address of a local variable or
temporary in (*itStop).second:
C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Tools\MSVC\14.30.30705\include\xutility(1582) : error C2220: the following warning is treated as an error
C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Tools\MSVC\14.30.30705\include\xutility(1582) : warning C4172: returning address of local variable or temporary
Avoid this by just iterating backwards.
Amends 6ed8a22dd2756557954dc85052870c0894de06ba.
Pick-to: 5.15 6.2 6.3
Change-Id: I01ce7cb151efa61e8702686b3a463790869df72c
Reviewed-by: Marc Mutz <marc.mutz@qt.io>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Diffstat (limited to 'src/qdoc/clangcodeparser.cpp')
0 files changed, 0 insertions, 0 deletions