cpprestsdk icon indicating copy to clipboard operation
cpprestsdk copied to clipboard

fundatmental issue - __cplusplus_winrt != UWP

Open mediabuff opened this issue 5 years ago • 2 comments

The library has genesis with support of C++/CX and assumes UWP is C++/CX and is replete with __cplusplus_winrt.

Which should'nt be the case as there are other c++ variants like cppwinrt. How do leverage this lib in cppwinrt context - and yet be binding to UWP apis not win32 apis.

Should this library code be converted from

#if __cplusplus_winrt
#endif

to

#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_PC_APP)
#endif

mediabuff avatar Jan 30 '20 12:01 mediabuff

Looks like this issue prevents microsoft-signalr from using the cpprestsdk on UWP.

BrennanConroy avatar Apr 24 '20 19:04 BrennanConroy

I think it should be

#if WINAPI_FAMILY == WINAPI_FAMILY_PC_APP
#endif

since __cplusplus_winrt means UWP only while WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_PC_APP) is UWP + Desktop

autoantwort avatar Sep 14 '23 14:09 autoantwort