feat: add Extras.DelayList and Extras.DelayMap, ported from the Flix standard library - #3
Merged
Merged
Conversation
…standard library Ports the DelayList and DelayMap modules and their tests from the Flix compiler repository (main/src/library/, identical to the v0.75.3 release). The only change to each source file is the module name, now under Extras; the only change to the tests is the `use` lines pointing at the extras modules. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YRutVsR79myxEkpYp7CCqA
magnus-madsen
added a commit
to flix/flix
that referenced
this pull request
Sep 12, 2026
The DelayList and DelayMap modules now live in the flix/extras package as Extras.DelayList and Extras.DelayMap (flix/extras#3). Remove them, and their tests, from the standard library. The flix/extras package is already part of the community build, so the extracted modules keep being compiled on every PR. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EUFSuSB8yJ9vdhvuBXzYht
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds
Extras.DelayListandExtras.DelayMap, ports of theDelayListandDelayMapmodules from the Flix standard library, together with their full test suites.What is ported
src/Extras/DelayList.flixandsrc/Extras/DelayMap.flixare copies of the compiler'smain/src/library/DelayList.flixandDelayMap.flix, both byte-identical to thev0.75.3release. The only change in each is the module declaration, now underExtras. The original copyright headers are preserved.test/TestDelayList.flixandtest/TestDelayMap.flixare copies of the compiler's tests. The only changes are theuselines pointing at the extras modules; the DelayList tests import the enum tags viause Extras.DelayList.{ENil, ECons, LCons, LList}. All 550 and 287 tests are included unchanged.src/Extras.flixand the README list the new modules.Dependencies outside the standard library
Checked against the
v0.75.3tag before porting:RedBlackTreefunction DelayMap calls ispub, with no@Internalannotation.Purity2,Purity3, and theMapconstructor used by DelayMap and its tests arepub.@Experimental,@Lazy,@LazyWhenPure,@Parallel, and@ParallelWhenPureannotations are recognized by the compiler with no stdlib-only restriction.Name resolution
Flix 0.75.3 still ships its own
DelayListandDelayMap. For DelayList the tests necessarily exercise the extras copy: the tags come explicitly fromExtras.DelayListand are passed toDelayListfunctions, which would not type-check against the standard library's distinct type. For DelayMap, resolution relies on the sameuseshadowing rule verified with a probe in #2.Testing
Ran
checkandtestwith the Flix 0.75.3 jar.🤖 Generated with Claude Code
https://claude.ai/code/session_01YRutVsR79myxEkpYp7CCqA