| 241 | } |
| 242 | |
| 243 | void cmGeneratedFileStream::WriteAltEncoding(std::string const& data, |
| 244 | Encoding encoding) |
| 245 | { |
| 246 | #ifndef CMAKE_BOOTSTRAP |
| 247 | std::locale prevLocale = |
| 248 | this->imbue(std::locale(this->getloc(), new codecvt(encoding))); |
| 249 | this->write(data.data(), data.size()); |
| 250 | this->imbue(prevLocale); |
| 251 | #else |
| 252 | static_cast<void>(encoding); |
| 253 | this->write(data.data(), data.size()); |
| 254 | #endif |
| 255 | } |