correct pragma controlling inlining behavior of JSON text encoding function

This commit is contained in:
Andrew Martin 2019-10-18 13:59:45 -04:00
parent f40f0c5623
commit da2be3281a

View file

@ -404,7 +404,7 @@ asWord8s (PrimArray x) = PrimArray x
-- Internal function. Precondition, the referenced slice of the -- Internal function. Precondition, the referenced slice of the
-- byte sequence is UTF-8 encoded text. -- byte sequence is UTF-8 encoded text.
slicedUtf8TextJson :: ByteArray# -> Int# -> Int# -> Builder slicedUtf8TextJson :: ByteArray# -> Int# -> Int# -> Builder
{-# inline slicedUtf8TextJson #-} {-# noinline slicedUtf8TextJson #-}
slicedUtf8TextJson !src# !soff0# !slen0# = fromFunction reqLen $ \dst doff0 -> do slicedUtf8TextJson !src# !soff0# !slen0# = fromFunction reqLen $ \dst doff0 -> do
PM.writeByteArray dst doff0 (c2w '"') PM.writeByteArray dst doff0 (c2w '"')
let go !soff !slen !doff = if slen > 0 let go !soff !slen !doff = if slen > 0