I have problem with Windows SDK.
There are .h header files. Classes declared in this files look like this:
namespace ABI {
namespace Windows {
namespace Devices {
namespace Bluetooth {
namespace Advertisement {
class BluetoothLEAdvertisementPublisher;
} /*Advertisement*/
} /*Bluetooth*/
} /*Devices*/
} /*Windows*/
}
When i want to create class, compiler raises me error 'allocation of incomplete type'.
BluetoothLEAdvertisementPublisher* x = new BluetoothLEAdvertisementPublisher();
What is going on. How should i use this? I have windows 10, C 11 and mingw compiler.
CodePudding user response:
BluetoothLEAdvertisementPublisher
comes with WinRT, not the Win32 API that MinGW provides.
So there is no way you will be able to compile that with MinGW/MinGW-w64 and you should try it with MSVC instead.