Is it possible to host the CLR in a C program?
问题 Every example I can find is in C++, but I'm trying to keep my project in C. Is it even possible to host the CLR in a C program? If so, can you point me to an example? 回答1: As the above comments hint, there is a set of COM APIs for hosting the CLR, and you should be able to call these COM APIs from both C and C++. As an example, below is a quick piece of (untested) C code that shows how to start up the CLR and execute a static method of a class in a managed assembly (which takes in a string as