We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e5d596e commit 327eedbCopy full SHA for 327eedb
1 file changed
examples/low_level_api/low_level_api_chat_cpp.py
@@ -493,7 +493,7 @@ def output(self):
493
# Contains multi-byte UTF8
494
for num, pattern in [(2, 192), (3, 224), (4, 240)]:
495
# Bitwise AND check
496
- if pattern & int.from_bytes(cur_char) == pattern:
+ if pattern & int.from_bytes(cur_char, 'little') == pattern:
497
self.multibyte_fix = [cur_char] + ([None] * (num-1))
498
499
# Stop incomplete bytes from passing
0 commit comments