这种强制转换一下类型就可以了。include <stdio.h>void print(const unsigned char* msg) { printf((char*)msg); printf("\n");}int main(){ char msg[] = "Hello world!"; print((unsigned char*)msg); return 0;} ...