This is C++ code:
#include <windows.h>
WINAPI DWORD threadFunc(LPVOID x) {
while (true) {
try {
throw 1;
} catch (...) {
}
}
return 0;
}
int main(int argc, char *argv[]) {
CreateThread(NULL, 0, threadFunc, NULL, 0, NULL);
CreateThread(NULL, 0, threadFunc, NULL, 0, NULL);
Sleep(1000);
return 0;
}
How can I convert it to Dlang?