를 제출 러시아어 문자 wstring을 쓸 수 없습니다, 다음 코드에서 C에서 ++ 코드 : 내용 input.tab내가 리눅스 (러시아어)는 wstrings을 쓰기 위해 노력하고있어
ofstream outWFile;
outWFile.open("input.tab");
outWFile<< WStringToString(w->get_form());
outWFile<<"\t";
outWFile<<WStringToString(w->get_tag());
std::string WStringToString(const std::wstring& s)
{
std::string temp(s.length(),' ');
std::copy(s.begin(), s.end(), temp.begin());
return temp;
}
가 무효
나는 stackoverflow에서 제안 된 것을 시도했다. Unable to write a std::wstring into wofstream 그러나 나는 도움이되지 못했다. 미리 감사드립니다.
가능한 중복 [A 표준을 쓸 :: wofstream에 wstring을 할 수 없습니다 (http://stackoverflow.com/questions/5104329/unable-to-write-a-stdwstring-into-wofstream) – Griwes
그 'ostream <<'은'outWFile'이어야합니까? – Etherealone
코드에 파일 쓰기가 전혀 표시되지 않고 표준 출력에만 표시됩니다. – bames53