Commit 2e76a84
Fix Fable compilation errors: guard ValueTask usage with #if FABLE_COMPILER
- In AsyncSeq.fs: wrap AsyncSeq<'T> type alias, AsyncSeqImpl<'T>, and
AsyncSeqEnumeratorExtensions with #if FABLE_COMPILER / #else / #endif.
For Fable: AsyncSeq<'T> is a library-specific interface with
GetEnumerator() returning IAsyncSeqEnumerator<'T>, avoiding ValueTask.
For non-Fable: keeps existing BCL IAsyncEnumerable<'T> alias and
ValueTask-based adapter.
- In AsyncSeq.fs: guard UnfoldAsyncEnumerator's IAsyncEnumerable<'T>
implementation of the library AsyncSeq<'T> interface instead.
- In AsyncSeq.fsi: add #if FABLE_COMPILER guard to expose
IAsyncSeqEnumerator<'T> and define AsyncSeq<'T> as interface for
Fable builds; keep BCL type alias for non-Fable.
Verified: dotnet build succeeds, 190/190 tests pass, dotnet fable
compiles without errors.
Co-authored-by: Copilot <[email protected]>1 parent 9a8ef05 commit 2e76a84
2 files changed
Lines changed: 39 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
29 | 42 | | |
30 | 43 | | |
31 | 44 | | |
| |||
72 | 85 | | |
73 | 86 | | |
74 | 87 | | |
| 88 | + | |
75 | 89 | | |
76 | 90 | | |
77 | 91 | | |
| |||
400 | 414 | | |
401 | 415 | | |
402 | 416 | | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
403 | 422 | | |
404 | 423 | | |
405 | 424 | | |
406 | 425 | | |
| 426 | + | |
407 | 427 | | |
408 | 428 | | |
409 | 429 | | |
| |||
1921 | 1941 | | |
1922 | 1942 | | |
1923 | 1943 | | |
| 1944 | + | |
1924 | 1945 | | |
1925 | 1946 | | |
1926 | 1947 | | |
| 1948 | + | |
1927 | 1949 | | |
1928 | 1950 | | |
1929 | | - | |
1930 | | - | |
| 1951 | + | |
| 1952 | + | |
1931 | 1953 | | |
1932 | 1954 | | |
1933 | 1955 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
6 | 18 | | |
7 | 19 | | |
8 | 20 | | |
9 | 21 | | |
| 22 | + | |
10 | 23 | | |
11 | 24 | | |
12 | 25 | | |
| |||
559 | 572 | | |
560 | 573 | | |
561 | 574 | | |
| 575 | + | |
562 | 576 | | |
563 | 577 | | |
564 | 578 | | |
| 579 | + | |
565 | 580 | | |
566 | 581 | | |
567 | 582 | | |
| |||
0 commit comments