char achar cstring 在 acutPrintf里的打印情况
程序员文章站
2024-03-18 12:56:28
...
char * ccchar = new char[50];
ccchar = "ccchar";
//acutPrintf(ccchar);
//acutPrintf(_T("ccchar \n"), TEXT(ccchar)); //语法错误
//acutPrintf(_T("ccchar \n"), _T(ccchar)); //语法错误
acutPrintf(ConvertCharPtrToAcharPtr(ccchar));
acutPrintf(_T("\n"));
ACHAR *aaachar = new ACHAR[100];
aaachar = TEXT("aaaachar");
acutPrintf(aaachar);
acutPrintf(_T("\n"));
CString ssschar,ccsschar;
ccsschar = ccchar;
ssschar = "sssschar";
acutPrintf(ssschar);
acutPrintf(_T("\n"));
acutPrintf(ccsschar);
acutPrintf(_T("\n"));
结果: