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

MSVC warnings 4718 in QMapData

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Not Evaluated
    • None
    • 5.7.0 Beta
    • None
    • Windows

    Description

      Although this was fixed in 5.6.0, in QT 5.7.0-beta, in Release (not Debug), the following warnings appear for every QMap.h included.

      \qtcore\qmap.h(133): warning C4718:
      'QMapNode<Cms::Private::ConstCharPointerKey,ComponentConstructorBase *>::doDestroySubTree' :
      recursive call has no side effects, deleting

      This was fixed in 5.6.0 in QtQTBUG-46649 "MSVC warnings 4718 and 4127 in QMapData".

      For every user, every include of Qmap.h, in release mode level 4, will get this warning.

      Workaround: (1) : Wrap all "#include <qmap.h>" with
      #pragma warning (disable : 4718)
      #include <qmap.h>
      #pragma warning (default : 4718)

      Workaround: (2) : Pragmatize all of-qmap.h OR pragma -doDestroySubTree definitions.
      #ifndef QMAP_H
      #define QMAP_H
      #pragma warning (disable : 4718)
      . . .
      #pragma warning (default : 4718)
      #endif // QMAP_H

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              thiago Thiago Macieira
              mstegehuis E.M. Stegehuis
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes