Bump FP to 1.8.1 + propagate Sendable#13
Merged
Conversation
FP 1.8.1 makes FunctionWrapper refine Sendable and requires @sendable closures across composition. Updates here: - Package.swift: bump FP from 1.7.0 to 1.8.1. - RequestPublisher's stored `run` closure and init are now @sendable (required by FunctionWrapper). - Functor / Applicative / Monad methods on RequestPublisher take @sendable closures: map, fmap, replace, mapError, flatMap, bind, kleisli, kleisliBack, flatMapError; pure requires A: Sendable; apply takes @sendable inner closure. - Operator overloads (<£>, <&>, £>, <£, >>-, -<<, >=>, <=<, <*>) match: @sendable closure parameters, @sendable curried returns where applicable. - TemplateValue enum (Context's value type) now conforms Sendable so the renderToken context capture is valid in a @sendable closure. - Test closures and typed lets annotated with @sendable where the new signatures require it. Build + tests green.
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.
Summary
RequestPublisher's storedrunclosure and init are now@Sendable(required by the FunctionWrapper conformance).RequestPublisherupdated to take@Sendableclosures:map,fmap,replace,mapError,flatMap,bind,kleisli,kleisliBack,flatMapError;purerequiresA: Sendable;applytakes@Sendableinner closure.<£>,<&>,£>,<£,>>-,-<<,>=>,<=<,<*>) match the same shape.TemplateValue(theContextvalue type) now conformsSendable.lets annotated with@Sendablewhere the new signatures require it.Test plan
swift build— greenswift test— all pass🤖 Generated with Claude Code