Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Problem with new Visual Studio update 2017 Version 15.9.4 and Qt 5.9.3

Problem with new Visual Studio update 2017 Version 15.9.4 and Qt 5.9.3

Scheduled Pinned Locked Moved Solved General and Desktop
visualstudio
9 Posts 6 Posters 6.2k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    Doctor G
    wrote on last edited by
    #1

    I have read the fix suggested in this forum titled: [https://forum.qt.io/topic/93711/problem-with-new-visual-studio-update-2017-version-15-8-0-and-qt-5-9-5](link url)

    It involved using a patched version of "qalgorithms.h", however that does not work for me.

    I am still getting the error:

    Error (active)	E2512	the argument to a feature-test macro must be a simple identifier
    in qcompilerdetection.h
    

    with Qt version Qt 5.9.3 (I cannot change the QT version, I am creating a DLL plugin for an very large program from a 3rd party).

    and VS Studio 15.9.4 (notice the higher version of VS2017).

    BTW, the solution was created by cmake and it says the C++ compiler is:
    MSVC 19.16.27025.1

    jsulmJ 1 Reply Last reply
    0
    • D Offline
      D Offline
      Doctor G
      wrote on last edited by
      #6

      I replace the qalgorithms.h cleaned the cmake cache, did a full rebuild. And now it is working for me also.

      I am using VS2017 15.9.4 and doing a x64 build with release symbols.

      The only odd thing I see, is that if there are any compile errors (other than these, then the E2512 error returns also. But that sort of behavior I see a lot with microsoft VC++ compiler, so don't sweat it.

      1 Reply Last reply
      0
      • D Doctor G

        I have read the fix suggested in this forum titled: [https://forum.qt.io/topic/93711/problem-with-new-visual-studio-update-2017-version-15-8-0-and-qt-5-9-5](link url)

        It involved using a patched version of "qalgorithms.h", however that does not work for me.

        I am still getting the error:

        Error (active)	E2512	the argument to a feature-test macro must be a simple identifier
        in qcompilerdetection.h
        

        with Qt version Qt 5.9.3 (I cannot change the QT version, I am creating a DLL plugin for an very large program from a 3rd party).

        and VS Studio 15.9.4 (notice the higher version of VS2017).

        BTW, the solution was created by cmake and it says the C++ compiler is:
        MSVC 19.16.27025.1

        jsulmJ Offline
        jsulmJ Offline
        jsulm
        Lifetime Qt Champion
        wrote on last edited by
        #2

        @Doctor-G According to https://en.wikipedia.org/wiki/Microsoft_Visual_C%2B%2B both versions you posted mean VS2017

        https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply
        0
        • Christian EhrlicherC Offline
          Christian EhrlicherC Offline
          Christian Ehrlicher
          Lifetime Qt Champion
          wrote on last edited by
          #3

          @Doctor-G said in Problem with new Visual Studio update 2017 Version 15.9.4 and Qt 5.9.3:

          Error (active) E2512 the argument to a feature-test macro must be a simple identifier
          in qcompilerdetection.h

          On which line exactly?

          Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
          Visit the Qt Academy at https://academy.qt.io/catalog

          1 Reply Last reply
          0
          • P Offline
            P Offline
            primem0ver
            wrote on last edited by primem0ver
            #4

            I am having this same problem. For me it is occurring on lines 1349 and 1351:

            #if QT_HAS_CPP_ATTRIBUTE(clang::fallthrough) //1349
            #    define Q_FALLTHROUGH() [[clang::fallthrough]]
            #elif QT_HAS_CPP_ATTRIBUTE(gnu::fallthrough) //1351
            #    define Q_FALLTHROUGH() [[gnu::fallthrough]]
            #elif QT_HAS_CPP_ATTRIBUTE(fallthrough)
            #  define Q_FALLTHROUGH() [[fallthrough]]
            #endif
            
            D 1 Reply Last reply
            0
            • Christian EhrlicherC Offline
              Christian EhrlicherC Offline
              Christian Ehrlicher
              Lifetime Qt Champion
              wrote on last edited by
              #5

              https://forum.qt.io/topic/93711/problem-with-new-visual-studio-update-2017-version-15-8-0-and-qt-5-9-5

              Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
              Visit the Qt Academy at https://academy.qt.io/catalog

              1 Reply Last reply
              3
              • D Offline
                D Offline
                Doctor G
                wrote on last edited by
                #6

                I replace the qalgorithms.h cleaned the cmake cache, did a full rebuild. And now it is working for me also.

                I am using VS2017 15.9.4 and doing a x64 build with release symbols.

                The only odd thing I see, is that if there are any compile errors (other than these, then the E2512 error returns also. But that sort of behavior I see a lot with microsoft VC++ compiler, so don't sweat it.

                1 Reply Last reply
                0
                • P primem0ver

                  I am having this same problem. For me it is occurring on lines 1349 and 1351:

                  #if QT_HAS_CPP_ATTRIBUTE(clang::fallthrough) //1349
                  #    define Q_FALLTHROUGH() [[clang::fallthrough]]
                  #elif QT_HAS_CPP_ATTRIBUTE(gnu::fallthrough) //1351
                  #    define Q_FALLTHROUGH() [[gnu::fallthrough]]
                  #elif QT_HAS_CPP_ATTRIBUTE(fallthrough)
                  #  define Q_FALLTHROUGH() [[fallthrough]]
                  #endif
                  
                  D Offline
                  D Offline
                  Doctor G
                  wrote on last edited by
                  #7

                  @primem0ver I was getting the errors on these same lines.

                  1 Reply Last reply
                  0
                  • lmasterL Offline
                    lmasterL Offline
                    lmaster
                    wrote on last edited by JKSH
                    #8

                    Time : 2019/3/7 16:38
                    vs2017 Enterprise 15.9.2
                    qt version : 12.1

                    0_1551948030135_a240b50f-04a9-4921-874d-48684934e966-image.png

                    0_1551948106259_5346ca21-b59b-47d3-a965-30e55ba63e38-image.png

                    what's wrong with me ...........

                    [EDIT: Email removed --JKSH]

                    1 Reply Last reply
                    1
                    • J Offline
                      J Offline
                      JWSchuetz
                      wrote on last edited by
                      #9

                      I had the same problem. Touching the header-file "qcompilerdetection.h" and recompilation solved the problem for me.

                      1 Reply Last reply
                      0

                      • Login

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • Users
                      • Groups
                      • Search
                      • Get Qt Extensions
                      • Unsolved