Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't compile WinRT application #16

Open
altk opened this issue Apr 7, 2016 · 2 comments
Open

Can't compile WinRT application #16

altk opened this issue Apr 7, 2016 · 2 comments

Comments

@altk
Copy link

altk commented Apr 7, 2016

Hello!!!
I tried to compile my WinRT application(fully written on C++, not C++/CX) with "CLang 3.7 with Microsoft Codegen (v140_clang_3_7)", but could not. I use Visual Studio 2015 Update 2 with March 2016 CLang.
Errors:

  1. C:\Program Files (x86)\Windows Kits\10\Include\10.0.10240.0\winrt\windows.foundation.collections.h(168,10): error : ISO C++ forbids forward references to 'enum' types
    enum CollectionsChange;
  2. C:\Program Files (x86)\Windows Kits\10\Include\10.0.10240.0\winrt\Windows.Foundation.h(8831,26): error : ISO C++ forbids forward references to 'enum' types
    typedef enum PropertyType PropertyType;

Another issue produced when compiling template
`template
struct NOVTABLE RemoveIUnknown abstract : TInterface
{
static_assert(std::is_base_of<IUnknown, TInterface>::value, "TInterface must inherit IUnknown");

operator TInterface*() NOEXCEPT
{
    return this;
}

private:
STDMETHODIMP_(ULONG) AddRef();
STDMETHODIMP_(ULONG) Release();
STDMETHODIMP QueryTInterface(IID, void **);
};`

variable has incomplete type 'struct RemoveIUnknown'
RemoveIUnknown abstract : TInterface

There were many others errors, but I think, that listed above are the most interesting.

@russellhadley
Copy link
Member

@AndrewPardoe are you minding Clang/C2 right now?

@AndrewPardoe
Copy link

Thanks for the report, @altk. We know that WRL is incompatible with our clang settings right now. I believe it will compile with ms-compatibility but as we try to move closer to standard clang defaults stuff in Windows is bound to break.

I've passed this report on to the owners of WRL.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants