mirror of https://github.com/grpc/grpc.git
Clang doesn't support adapting calling convention when converting a non-capturing lambda into a function pointer, and it doesn't support tagging a lambda with calling convention AFAICT. In thd_windows.cc, we create the thread body lambda and pass it to CreateThread(), which fails to build on clang because it cannot convert the lambda into stdcall function. Note that this bug only happens when building for x32 architecture. x64 is not affected because there is only one standard x64 calling convention. This change fixes this by moving the thread body logic into a private static method and tagging it with WINAPI (which expands to __stdcall).pull/18097/head
parent
b3b5d63423
commit
72035e7265
1 changed files with 15 additions and 18 deletions
Loading…
Reference in new issue