Ask for help! Build error in CUDA

I have written codes for the kernel,but after building solution,there is an error which said :“can’t generate code for non empty constructors or destructors on device”,I don’t know why this happened,and how to solve this problem,So I ask for help,Thank you very much!