diff --git a/src/FSharpy.TaskSeq/TaskSeqBuilder.fs b/src/FSharpy.TaskSeq/TaskSeqBuilder.fs index 1b42f7c7..16db4470 100644 --- a/src/FSharpy.TaskSeq/TaskSeqBuilder.fs +++ b/src/FSharpy.TaskSeq/TaskSeqBuilder.fs @@ -155,7 +155,6 @@ and [] TaskSeq<'Machine, 'T data.builder <- AsyncIteratorMethodBuilder.Create() machine.Data <- data - member internal this.hijack() = let res = this._machine.Data.tailcallTarget @@ -216,6 +215,7 @@ and [] TaskSeq<'Machine, 'T (this._machine.Data.promiseOfValueOrEnd.GetStatus(token)) this._machine.Data.promiseOfValueOrEnd.GetResult(token) + with e -> // FYI: an exception here is usually caused by the CE statement (user code) throwing an exception // We're just logging here because the following error would also be caught right here: @@ -253,8 +253,6 @@ and [] TaskSeq<'Machine, 'T this // just return 'self' here | _ -> - if verbose then - printfn "GetAsyncEnumerator, cloning..." // We need to reset state, but only to the "initial machine", resetting the _machine to // Unchecked.defaultof<_> is wrong, as the compiler uses this to track state. However,