请教c++ thread 如何在主函数以外的一个函数里调用其他的函数
#include"stdafx.h"
#include <iostream>
#include <thread>
using namespace std;
void Judge(int x, int y, int z)
{
thread taskUD(UDjudge, x, y, z);
taskUD.detach();
}
int UDjudge(int x,int y,int z)
{
.........
}
int main()
{
int x,y,z;
Judge(x,y,z);
return 0;
}
像是这样的,在VS2017编译时会显示在thread那一行.显示"UDjudge"是未定义的标识符,错误代码C2065
请问这该如何解决?