Details
-
Bug
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
6.6
-
None
-
bc2675570 (108-based)
Description
Download following mingw build:
Try to compile following program and see the output
#include <windows.foundation.h> int main() { return 0; } D:\>C:/opt/mingw64/bin/g++.exe -std=gnu++17 main.cc -o main.exe In file included from main.cc:1: C:/opt/mingw64/x86_64-w64-mingw32/include/windows.foundation.h:91:26: error: use of enum 'PropertyType' without previous declaration 91 | typedef enum PropertyType PropertyType; | ^~~~~~~~~~~~ C:/opt/mingw64/x86_64-w64-mingw32/include/windows.foundation.h:165:18: error: using typedef-name 'ABI::Windows::Foundation::PropertyType' after 'enum' 165 | enum PropertyType { | ^~~~~~~~~~~~ C:/opt/mingw64/x86_64-w64-mingw32/include/windows.foundation.h:91:39: note: 'ABI::Windows::Foundation::PropertyType' has a previous declaration here 91 | typedef enum PropertyType PropertyType; | ^~~~~~~~~~~~
Take a look into windows.foundation.h and note:
- it is autogenerated
- content is incorrect as compiler complains about doing type aliasing for undeclared enum
Consider patching it fix it with one of
- remove bougs enum typedef
- adding forward declaration :
enum class PropertyType or enum PropertyType: int;
... namespace Foundation { enum class PropertyType; typedef enum PropertyType PropertyType; } ...
It requires also fixing definition later in that header.
Attachments
Issue Links
- relates to
-
QTBUG-111362 QtPdf support for mingw
- Closed