Skip to content
Closed
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
3cec0d7
Add a bunch of multiple iteration tests
abelbraaksma Oct 16, 2022
e3fdee7
Adding several comments and log statements to get to the bottom of th…
abelbraaksma Oct 17, 2022
68e632e
Issue #39, adding bunch of tests that show various ways of getting In…
abelbraaksma Oct 22, 2022
dc7dcca
Add (failing) tests for calling IAsyncEnumerator.Current *before* ite…
abelbraaksma Oct 22, 2022
cf1c24d
Fix: do not throw an exception on IAsyncEnumerator.Current when undef…
abelbraaksma Oct 22, 2022
63fc705
Add (currently failing) tests for transitioning state to *after* sequ…
abelbraaksma Oct 22, 2022
da0a1ce
Fix tests, Fact vs Theory
abelbraaksma Oct 22, 2022
d8f9865
Fix: ensure Current returns Unchecked.defaultof when *beyond* the end…
abelbraaksma Oct 22, 2022
b27b11e
Improve verbosity printing
abelbraaksma Oct 22, 2022
817d6f7
Record whether or not the IAsyncEnumerable is "past completion", whic…
abelbraaksma Oct 22, 2022
1e318c1
Make the test's code a little more readable
abelbraaksma Oct 22, 2022
c537169
Add two tests the show the difference in behavior between two seq pro…
abelbraaksma Oct 22, 2022
fe8f5d4
Renaming 'this' pointer for clarity, ts -> this.
abelbraaksma Oct 22, 2022
33739e7
Initialize new TaskSeqStateMachineData() when getting a new enumerator
abelbraaksma Oct 22, 2022
98c4fc1
Add test for basic case of incorrect MoveNext state after creating ne…
abelbraaksma Oct 22, 2022
b1b29bb
Fix incorrect ResumptionPoint resume by force-resetting the `Machine`…
abelbraaksma Oct 24, 2022
667468a
Add a (failing) test to investigate Faulted state with multiple itera…
abelbraaksma Oct 24, 2022
2deb71d
Adding a bunch of variants with delayed yields to check proper state …
abelbraaksma Oct 24, 2022
2d999a0
Disable a bunch of tests, and set verbose=false, as CI cannot deal wi…
abelbraaksma Oct 24, 2022
e03acd7
Fix rebase mistake
abelbraaksma Oct 24, 2022
8fb8282
Temp disable worrisome tests to get xUnit to complete in CI
abelbraaksma Oct 24, 2022
b597e4d
Show that the NRE can also occur in synchronous versions of taskSeq
abelbraaksma Oct 24, 2022
c095488
Add two more tests, and improve logging
abelbraaksma Oct 26, 2022
ce61525
use copy of initial state machine to get resumption back to zero
dsyme Oct 28, 2022
5226d27
use copy of initial state machine to get resumption back to zero
dsyme Oct 28, 2022
0caf11d
use copy of initial state machine to get resumption back to zero
dsyme Oct 28, 2022
f562304
Merge branch 'main' into a
abelbraaksma Oct 29, 2022
b809967
Fix merge mistakes
abelbraaksma Oct 29, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions src/FSharpy.TaskSeq/TaskSeqBuilder.fs
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,6 @@ and [<NoComparison; NoEquality>] TaskSeq<'Machine, 'T
data.builder <- AsyncIteratorMethodBuilder.Create()
machine.Data <- data


member internal this.hijack() =
let res = this._machine.Data.tailcallTarget

Expand Down Expand Up @@ -216,6 +215,7 @@ and [<NoComparison; NoEquality>] 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:
Expand Down Expand Up @@ -253,8 +253,6 @@ and [<NoComparison; NoEquality>] 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,
Expand Down