Instead of
CreateThread(NULL, NULL, function, NULL, NULL, NULL);
I was interested in trying
CreateThread(NULL, NULL, [](LPTHREAD_START_ROUTINE){ int x = 0; return x;}, NULL, NULL, NULL);
I get ERROR: No suitable conversion function from lambda []int (LPTHREAD_START_ROUTINE)->int to LPTHREAD_START_ROUTINE exists.