We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e25311b commit 0ce634dCopy full SHA for 0ce634d
1 file changed
examples/disco/example.cpp
@@ -16,8 +16,8 @@ using disco::Recommender;
16
17
std::string convert_to_utf8(const std::string& str) {
18
std::stringstream buf;
19
- for (const auto& v : str) {
20
- if (v >= 0) {
+ for (const unsigned char v : str) {
+ if (v < 128) {
21
buf << v;
22
} else {
23
buf << static_cast<char>(195) << static_cast<char>(v - 64);
0 commit comments