Redesign stream as union and add streams.Enumerate (#908)#1042
Open
Redesign stream as union and add streams.Enumerate (#908)#1042
Conversation
cb7ebc0 to
5d9b918
Compare
b22306f to
c493af0
Compare
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.
Context
Implements core migration for #908 in scope of tracker #1033.
What is done
stream<T>from struct to tagged union (Open | Data T | Close)streams.Indexed<T>,streams.Enumerate<T>,streams.Just<T>IsData/IsClose/UnwrapData)streams.ForEachvia runtime controller (stream_for_each_controller) to preserve ordering and backpressurestreams.Filterevent routing under union-stream semanticsVerification
Passing:
go test ./internal/runtime/funcs ./examples/filter_list -count=1 -timeout 5mgo test ./examples/for_loop_over_list -count=1 -timeout 8mgo test ./examples/filter_list ./examples/for_loop_over_list -count=1 -timeout 9mNote:
golangci-lintbinary in this environment is built with older Go (go1.25), so directgolangci-lint run ./...is blocked against targetgo1.26.0.Refs #908
Refs #1033