Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Compilation error with Visual Studio



  • I am using Visual studio 2019 with compilor v120 and qt 5.15
    Error code like following, I have no idea where to look for the issue. Is there anyone seen similar issue?:
    3>c:\qt\5.15.2\msvc2019\include\qtcore\qglobal.h(391): error C2146: syntax error : missing ';' before identifier 'Deprecated_t'
    3>c:\qt\5.15.2\msvc2019\include\qtcore\qglobal.h(391): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    3>c:\qt\5.15.2\msvc2019\include\qtcore\qglobal.h(477): error C3646: 'noexcept' : unknown override specifier
    3>c:\qt\5.15.2\msvc2019\include\qtcore\qglobal.h(663): error C2143: syntax error : missing ';' before '<cv-qualifer>'
    3>c:\qt\5.15.2\msvc2019\include\qtcore\qglobal.h(663): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    3>c:\qt\5.15.2\msvc2019\include\qtcore\qglobal.h(663): error C2143: syntax error : missing ';' before '&'
    3>c:\qt\5.15.2\msvc2019\include\qtcore\qglobal.h(663): error C2143: syntax error : missing ',' before '&'
    3>c:\qt\5.15.2\msvc2019\include\qtcore\qglobal.h(665): error C2143: syntax error : missing ';' before '<cv-qualifer>'
    3>c:\qt\5.15.2\msvc2019\include\qtcore\qglobal.h(665): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    3>c:\qt\5.15.2\msvc2019\include\qtcore\qglobal.h(665): error C2143: syntax error : missing ';' before '&'
    3>c:\qt\5.15.2\msvc2019\include\qtcore\qglobal.h(665): error C2143: syntax error : missing ',' before '&'



  • @chiyuwang Check for the required header file for inclusion and c++ standard


Log in to reply