Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-84584

MSVC warns on std::is_permutation in QHash header

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P3: Somewhat important
    • None
    • 5.15.0
    • None
    • Windows

    Description

      When compiling an application with Qt 5.15.0 and MSVC2017, I get the following warnings:

      ERROR: C:\Python38\Scripts\clcache.exe "C:/Program Files (x86)/Microsoft Visual Studio/2017/BuildTools/VC/Tools/MSVC/14.16.27023/bin/Hostx64/x64/cl.exe" /nologo /c /EHsc /O2 /MD /WX /IC:\Users\travis\build\rweickelt\qbs\src\lib\corelib /IC:\Users\travis\build\rweickelt\qbs\src /IC:\Users\travis\Qt\5.15.0\msvc2017_64\include /IC:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtCore /IC:\Users\travis\Qt\5.15.0\msvc2017_64\mkspecs\win32-msvc /IC:\Users\travis\build\rweickelt\qbs\release\qbscore.379038de\qt.headers /IC:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtCore\5.15.0 /IC:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtCore\5.15.0\QtCore /IC:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtGui /IC:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtANGLE /IC:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtNetwork /IC:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtScript /IC:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtXml /DNDEBUG /DUNICODE /D_UNICODE /DWIN32 /DQT_NO_CAST_FROM_ASCII /DQT_NO_CAST_FROM_BYTEARRAY /DQT_NO_PROCESS_COMBINED_ARGUMENT_START /D_SCL_SECURE_NO_WARNINGS /DQBS_LIBRARY "/DQBS_RELATIVE_LIBEXEC_PATH=\"../bin\"" "/DQBS_VERSION=\"1.17.0\"" /DQBS_ENABLE_PROJECT_FILE_UPDATES /DQBS_ENABLE_UNIT_TESTS /DQT_CORE_LIB /DQT_NO_DEBUG /DQT_GUI_LIB /DQT_NETWORK_LIB /DQT_SCRIPT_LIB /DQT_XML_LIB "/DWINVER=0x0502" "/D_WIN32_WINNT=0x0502" "/D_WIN32_WINDOWS=0x0502" /FoC:\Users\travis\build\rweickelt\qbs\release\qbscore.379038de\c04c9fa8cb2f8855\timestampsupdater.cpp.obj C:\Users\travis\build\rweickelt\qbs\src\lib\corelib\buildgraph\timestampsupdater.cpp /TP /std:c++14 /FS
      C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\include\xutility(3638): error C2220: warning treated as error - no 'object' file generated
      C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\include\xutility(3638): warning C4996: 'QHash<T,QHashDummyValue>::const_iterator::operator --': was declared deprecated
              with
              [
                  T=QString
              ]
      C:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtCore/qhash.h(435): note: see declaration of 'QHash<T,QHashDummyValue>::const_iterator::operator --'
              with
              [
                  T=QString
              ]
      C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\include\xutility(3654): note: see reference to function template instantiation 'void std::_Trim_matching_suffixes<_FwdIt1,_FwdIt2,_Pr>(_FwdIt1 &,_FwdIt2 &,_Pr,std::bidirectional_iterator_tag,std::bidirectional_iterator_tag)' being compiled
              with
              [
                  _FwdIt1=QHash<QString,QHashDummyValue>::const_iterator,
                  _FwdIt2=QHash<QString,QHashDummyValue>::const_iterator,
                  _Pr=std::equal_to<void>
              ]
      C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\include\xutility(3758): note: see reference to function template instantiation 'bool std::_Check_match_counts<_FwdIt1,_FwdIt2,_Pr>(_FwdIt1,_FwdIt1,_FwdIt2,_FwdIt2,_Pr)' being compiled
              with
              [
                  _FwdIt1=QHash<QString,QHashDummyValue>::const_iterator,
                  _FwdIt2=QHash<QString,QHashDummyValue>::const_iterator,
                  _Pr=std::equal_to<void>
              ]
      C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\include\xutility(3797): note: see reference to function template instantiation 'bool std::_Is_permutation_unchecked<_Iter,_Iter,_Fn>(_FwdIt1,_FwdIt1,_FwdIt2,_FwdIt2,_Pr,std::forward_iterator_tag,std::forward_iterator_tag)' being compiled
              with
              [
                  _Iter=QHash<QString,QHashDummyValue>::const_iterator,
                  _Fn=std::equal_to<void>,
                  _FwdIt1=QHash<QString,QHashDummyValue>::const_iterator,
                  _FwdIt2=QHash<QString,QHashDummyValue>::const_iterator,
                  _Pr=std::equal_to<void>
              ]
      C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\include\xutility(3806): note: see reference to function template instantiation 'bool std::is_permutation<_FwdIt1,_FwdIt2,std::equal_to<void>>(_FwdIt1,_FwdIt1,_FwdIt2,_FwdIt2,_Pr)' being compiled
              with
              [
                  _FwdIt1=QHash<QString,QHashDummyValue>::const_iterator,
                  _FwdIt2=QHash<QString,QHashDummyValue>::const_iterator,
                  _Pr=std::equal_to<void>
              ]
      C:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtCore/qglobal.h(1034): note: see reference to function template instantiation 'bool std::is_permutation<ForwardIterator1,ForwardIterator2>(_FwdIt1,_FwdIt1,_FwdIt2,_FwdIt2)' being compiled
              with
              [
                  ForwardIterator1=QHash<QString,QHashDummyValue>::const_iterator,
                  ForwardIterator2=QHash<QString,QHashDummyValue>::const_iterator,
                  _FwdIt1=QHash<QString,QHashDummyValue>::const_iterator,
                  _FwdIt2=QHash<QString,QHashDummyValue>::const_iterator
              ]
      C:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtCore/qhash.h(967): note: see reference to function template instantiation 'bool qt_is_permutation<QHash<T,QHashDummyValue>::const_iterator,T1>(ForwardIterator1,ForwardIterator1,ForwardIterator2,ForwardIterator2)' being compiled
              with
              [
                  T=QString,
                  T1=QHash<QString,QHashDummyValue>::const_iterator,
                  ForwardIterator1=QHash<QString,QHashDummyValue>::const_iterator,
                  ForwardIterator2=QHash<QString,QHashDummyValue>::const_iterator
              ]
      C:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtCore/qhash.h(942): note: while compiling class template member function 'bool QHash<T,QHashDummyValue>::operator ==(const QHash<T,QHashDummyValue> &) const'
              with
              [
                  T=QString
              ]
      C:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtCore/qset.h(75): note: see reference to function template instantiation 'bool QHash<T,QHashDummyValue>::operator ==(const QHash<T,QHashDummyValue> &) const' being compiled
              with
              [
                  T=QString
              ]
      C:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtCore/qset.h(271): note: see reference to class template instantiation 'QHash<T,QHashDummyValue>' being compiled
              with
              [
                  T=QString
              ]
      c:\users\travis\build\rweickelt\qbs\src\lib\corelib\language\jsimports.h(83): note: see reference to class template instantiation 'QSet<T>' being compiled
              with
              [
                  T=QString
              ]
      C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\include\xutility(3639): warning C4996: 'QHash<T,QHashDummyValue>::const_iterator::operator --': was declared deprecated
              with
              [
                  T=QString
              ]
      C:\Users\travis\Qt\5.15.0\msvc2017_64\include\QtCore/qhash.h(435): note: see declaration of 'QHash<T,QHashDummyValue>::const_iterator::operator --'
              with
              [
                  T=QString
              ]
      The command "scripts/build-qbs-with-qbs.sh" exited with 1.
      

      This looks quite similar to https://bugreports.qt.io/browse/QTBUG-61902.

      I am using the Qt binaries provided here: http://download.qt.io/online/qtsdkrepository/windows_x86/desktop/qt5_5150/qt.qt5.5150.win64_msvc2017_64/

      Attachments

        Issue Links

          For Gerrit Dashboard: QTBUG-84584
          # Subject Branch Project Status CR V

          Activity

            People

              laknoll Lars Knoll
              rweickelt Richard Weickelt
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes