Skip to content

Commit 03599c4

Browse files
committed
Use Text.Encoding.decodeLatin1 for decoding ASCII strings
1 parent d0fd406 commit 03599c4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Data/Aeson/Parser/Internal.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@ jstring_ = do
322322
-- not sure whether >= or bit hackery is faster
323323
-- perfectly, we shouldn't care, it's compiler job.
324324
s <- A.takeWhile (\w -> w /= DOUBLE_QUOTE && w /= BACKSLASH && w >= 0x20 && w < 0x80)
325-
let txt = TE.decodeUtf8 s
325+
let txt = TE.decodeLatin1 s
326326
mw <- A.peekWord8
327327
case mw of
328328
Nothing -> fail "string without end"

0 commit comments

Comments
 (0)