У меня есть канал производителя, и я использовал канал печати. Я хотел бы записать вывод в файл. Если я использую Control.Data.sinkFile, например
test2file = runPipe $ CB.sinkFile "testOutput" <+< traverseTree fn3
Я получаю ошибку типа:
Couldn't match expected type `Pipe
b0 void-0.5.8:Data.Void.Void m0 r0'
with actual type `Data.Conduit.Internal.Pipe
l0 Data.ByteString.Internal.ByteString o0 r1 m1 r1'
In the return type of a call of `sinkFile'
In the first argument of `(<+<)', namely `sinkFile "testOutput"'
Как мне преобразовать sinkFile в канал, который можно составить. есть ли строгий или ленивый вопрос?
traverseTree
функцией, которую вы определили? - person huon   schedule 29.09.2012