Skip to content

Resolve Swift Async Algorithms import conflicts - #39

Merged
twittemb merged 4 commits into
sideeffect-io:mainfrom
lachenmayer:fix/remove-swift-async-algorithms-overlaps
Oct 3, 2026
Merged

twittemb merged 4 commits into
sideeffect-io:mainfrom
lachenmayer:fix/remove-swift-async-algorithms-overlaps

Conversation

@lachenmayer

@lachenmayer lachenmayer commented Dec 6, 2023 •

Copy link
Copy Markdown
Contributor

Importing AsyncExtensions and Swift Async Algorithms together makes Sequence.async, the fixed two- and three-input zip/merge APIs, and the AsyncTimerSequence type ambiguous. This change delegates .async and the fixed combiners to AsyncAlgorithms, removes their duplicate implementations and unused internal code, and renames AsyncExtensions’ buffered Date timer to AsyncBufferedTimerSequence while preserving its behavior.

Preserve AsyncExtensions’ variadic zip/merge and explicit AsyncLazySequence constructor. Update the remaining tests to import AsyncAlgorithms where needed and explicitly exercise AsyncExtensions’ variadic operators. Add eight coexistence tests covering .async, Apple’s fixed overloads, AsyncExtensions’ four-input overloads, and both timer types. Rebase onto current main, retaining its subject and cancellation fixes.

This is a breaking API migration: callers using the removed APIs must add the AsyncAlgorithms product dependency and import, and callers using the buffered Date timer must adopt its new name. README and changelog include migration guidance. The package now requires Swift 5.8 for the AsyncAlgorithms test dependency; the production target retains only its Collections dependency.

Validation on macOS with Swift 6.4:

  • Full suite with coverage: 171 tests passed using AsyncAlgorithms 1.0.0 and Collections 1.0.5.
  • Compatibility tests: all eight passed with AsyncAlgorithms 1.1.7 and Collections 1.7.1 in an isolated dependency-update check.
  • git diff --check passed.

lachenmayer and others added 3 commits October 3, 2026 12:28
Preserve variadic zip and merge and the explicit AsyncLazySequence constructor. Remove the conflicting Sequence.async extension and unused fixed-arity merge setup, repair test imports, and cover both modules together.
@twittemb
twittemb force-pushed the fix/remove-swift-async-algorithms-overlaps branch from ce1bf5d to b015aa7 Compare October 3, 2026 10:44
@twittemb twittemb changed the title Fix: remove overlapping operators from swift-async-algorithms Resolve Swift Async Algorithms import conflicts Oct 3, 2026
@twittemb
twittemb merged commit a7d0a95 into sideeffect-io:main Oct 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants