Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-24244

Project templates use outdated QT_DEPRECATED_WARNINGS

XMLWordPrintable

    • 59b84c8d19bdaac6cdafba2bd0173113a7a1bdc8 (qt-creator/qt-creator/4.13)

      When creating e.g. a new Qt Widgets application in Qt Creator, the .pro file contains the following block:

      # The following define makes your compiler emit warnings if you use
      # any Qt feature that has been marked deprecated (the exact warnings
      # depend on your compiler). Please consult the documentation of the
      # deprecated API in order to know how to port your code away from it.
      DEFINES += QT_DEPRECATED_WARNINGS

      The Qt documentation here says:
      QT_DEPRECATED_WARNINGS
      Since Qt 5.13, this macro has no effect. In Qt 5.12 and before, if this macro is defined, the compiler will generate warnings if any API declared as deprecated by Qt is used.

      The templates are misleading here, because they guide a user into using a deprecated define. This is especially confusing for those who want to play around with the new deprecations in Qt 5.15.

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

            kandeler Christian Kandeler
            markus.maier Markus Haberlander
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes