unpackCStringBA#, -- :: ByteArray# -> Int# -> [Char]
unpackNBytesBA#, -- :: ByteArray# -> Int# -> [Char]
+#ifndef __PARALLEL_HASKELL__
unpackCStringFO, -- :: ForeignObj -> [Char]
unpackNBytesFO, -- :: ForeignObj -> Int -> [Char]
unpackCStringFO#, -- :: ForeignObj# -> [Char]
unpackNBytesFO#, -- :: ForeignObj# -> Int# -> [Char]
+#endif
unpackFoldrCString#, -- **
unpackAppendCString# -- **
of the code above).
\begin{code}
+#ifndef __PARALLEL_HASKELL__
unpackCStringFO :: ForeignObj -> [Char]
unpackCStringFO (ForeignObj fo#) = unpackCStringFO# fo#
| otherwise = C# ch : unpack (i +# 1#)
where
ch = indexCharOffForeignObj# fo i
+#endif
\end{code}
import PackBase ( unpackNBytesST )
import PrelBase
import GHC
-import Foreign ( ForeignObj, Addr, makeForeignObj, writeForeignObj )
+import Foreign ( Addr,
+#ifndef __PARALLEL_HASKELL__
+ ForeignObj, makeForeignObj, writeForeignObj
+#endif
+ )
+
import Char ( ord, chr )
\end{code}