@@ -1,4 +1,4 @@
1−{-# LANGUAGE OverloadedStrings #-}
1+{-# LANGUAGE BangPatterns, OverloadedStrings #-}
22
33-- |
44-- Module: Data.Aeson.Encode
@@ -63,7 +63,7 @@ string s = {-# SCC "string" #-} singleton '"' <> quote s <> singleton '"'
6363 where
6464 quote q = case T.uncons t of
6565 Nothing -> fromText h
66− Just (c,t') -> fromText h <> escape c <> quote t'
66+ Just (!c,t') -> fromText h <> escape c <> quote t'
6767 where (h,t) = {-# SCC "break" #-} T.break isEscape q
6868 isEscape c = c == '\"' || c == '\\' || c < '\x20'
6969 escape '\"' = "\\\""