diff --git a/release-notes.txt b/release-notes.txt index de5ed45a..e901fc4b 100644 --- a/release-notes.txt +++ b/release-notes.txt @@ -1,9 +1,10 @@ Release notes: 0.4.x (unreleased) - - overhaul all doc comments, add exceptions info, improve tooltips experience, #136 - - DEPRECATED: type 'TaskSeq<'T>' now replaces 'taskSeq<'T>', the latter deprecated FS0044, #187 - - BINARY INCOMPATIBLE: TaskSeq module members are now static members, source code compatible, #186 + - overhaul all doc comments, add exceptions, improve editor experience, #136 + - DEPRECATED: 'taskSeq<_>' renamed to 'TaskSeq<_>', 'taskSeq' warns with FS0044, #187 + - BINARY INCOMPATIBILITY: 'TaskSeq' module is now static members on 'TaskSeq<_>', fixes #184 + - Performance: less thread hops with 'StartImmediateAsTask' instead of 'StartAsTask', fixes #135 0.4.0-alpha.1 - fixes not calling Dispose for 'use!', 'use', or `finally` blocks #157 (by @bartelink) diff --git a/src/FSharp.Control.TaskSeq/AsyncExtensions.fs b/src/FSharp.Control.TaskSeq/AsyncExtensions.fs index 0230395f..261e3437 100644 --- a/src/FSharp.Control.TaskSeq/AsyncExtensions.fs +++ b/src/FSharp.Control.TaskSeq/AsyncExtensions.fs @@ -8,5 +8,5 @@ module AsyncExtensions = member _.For(source: TaskSeq<'T>, action: 'T -> Async) = source - |> TaskSeq.iterAsync (action >> Async.StartAsTask) + |> TaskSeq.iterAsync (action >> Async.StartImmediateAsTask) |> Async.AwaitTask diff --git a/src/FSharp.Control.TaskSeq/TaskSeqBuilder.fs b/src/FSharp.Control.TaskSeq/TaskSeqBuilder.fs index 87e3dbcc..94af1b8b 100644 --- a/src/FSharp.Control.TaskSeq/TaskSeqBuilder.fs +++ b/src/FSharp.Control.TaskSeq/TaskSeqBuilder.fs @@ -648,7 +648,7 @@ module HighPriority = ResumableTSC<'U>(fun sm -> let mutable awaiter = Async - .StartAsTask(computation, cancellationToken = sm.Data.cancellationToken) + .StartImmediateAsTask(computation, cancellationToken = sm.Data.cancellationToken) .GetAwaiter() let mutable __stack_fin = true