effect 2.0.0-next.37 → 2.0.0-next.39
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Bigint/dist/effect-Bigint.cjs.dev.js +5 -5
- package/Bigint/dist/effect-Bigint.cjs.prod.js +5 -5
- package/Bigint/dist/effect-Bigint.esm.js +346 -5
- package/Boolean/dist/effect-Boolean.cjs.dev.js +5 -5
- package/Boolean/dist/effect-Boolean.cjs.prod.js +5 -5
- package/Boolean/dist/effect-Boolean.esm.js +230 -5
- package/Brand/dist/effect-Brand.cjs.dev.js +20 -20
- package/Brand/dist/effect-Brand.cjs.prod.js +20 -20
- package/Brand/dist/effect-Brand.esm.js +204 -20
- package/Cache/dist/effect-Cache.cjs.dev.js +72 -72
- package/Cache/dist/effect-Cache.cjs.prod.js +72 -72
- package/Cache/dist/effect-Cache.esm.js +111 -74
- package/Cause/dist/effect-Cause.cjs.dev.js +32 -32
- package/Cause/dist/effect-Cause.cjs.prod.js +32 -32
- package/Cause/dist/effect-Cause.esm.js +668 -33
- package/Channel/dist/effect-Channel.cjs.dev.js +105 -105
- package/Channel/dist/effect-Channel.cjs.prod.js +105 -105
- package/Channel/dist/effect-Channel.esm.js +1001 -107
- package/ChannelChildExecutorDecision/dist/effect-ChannelChildExecutorDecision.cjs.dev.js +3 -3
- package/ChannelChildExecutorDecision/dist/effect-ChannelChildExecutorDecision.cjs.prod.js +3 -3
- package/ChannelChildExecutorDecision/dist/effect-ChannelChildExecutorDecision.esm.js +112 -3
- package/ChannelMergeDecision/dist/effect-ChannelMergeDecision.cjs.dev.js +3 -3
- package/ChannelMergeDecision/dist/effect-ChannelMergeDecision.cjs.prod.js +3 -3
- package/ChannelMergeDecision/dist/effect-ChannelMergeDecision.esm.js +60 -3
- package/ChannelMergeState/dist/effect-ChannelMergeState.cjs.dev.js +3 -3
- package/ChannelMergeState/dist/effect-ChannelMergeState.cjs.prod.js +3 -3
- package/ChannelMergeState/dist/effect-ChannelMergeState.esm.js +101 -3
- package/ChannelMergeStrategy/dist/effect-ChannelMergeStrategy.cjs.dev.js +3 -3
- package/ChannelMergeStrategy/dist/effect-ChannelMergeStrategy.cjs.prod.js +3 -3
- package/ChannelMergeStrategy/dist/effect-ChannelMergeStrategy.esm.js +84 -3
- package/ChannelSingleProducerAsyncInput/dist/effect-ChannelSingleProducerAsyncInput.cjs.dev.js +89 -89
- package/ChannelSingleProducerAsyncInput/dist/effect-ChannelSingleProducerAsyncInput.cjs.prod.js +89 -89
- package/ChannelSingleProducerAsyncInput/dist/effect-ChannelSingleProducerAsyncInput.esm.js +47 -91
- package/ChannelUpstreamPullRequest/dist/effect-ChannelUpstreamPullRequest.cjs.dev.js +3 -3
- package/ChannelUpstreamPullRequest/dist/effect-ChannelUpstreamPullRequest.cjs.prod.js +3 -3
- package/ChannelUpstreamPullRequest/dist/effect-ChannelUpstreamPullRequest.esm.js +84 -3
- package/ChannelUpstreamPullStrategy/dist/effect-ChannelUpstreamPullStrategy.cjs.dev.js +3 -3
- package/ChannelUpstreamPullStrategy/dist/effect-ChannelUpstreamPullStrategy.cjs.prod.js +3 -3
- package/ChannelUpstreamPullStrategy/dist/effect-ChannelUpstreamPullStrategy.esm.js +83 -3
- package/Chunk/dist/effect-Chunk.cjs.dev.js +20 -20
- package/Chunk/dist/effect-Chunk.cjs.prod.js +20 -20
- package/Chunk/dist/effect-Chunk.esm.js +1084 -20
- package/Clock/dist/effect-Clock.cjs.dev.js +40 -40
- package/Clock/dist/effect-Clock.cjs.prod.js +40 -40
- package/Clock/dist/effect-Clock.esm.js +78 -42
- package/Config/dist/effect-Config.cjs.dev.js +36 -36
- package/Config/dist/effect-Config.cjs.prod.js +36 -36
- package/Config/dist/effect-Config.esm.js +321 -37
- package/ConfigError/dist/effect-ConfigError.cjs.dev.js +21 -21
- package/ConfigError/dist/effect-ConfigError.cjs.prod.js +21 -21
- package/ConfigError/dist/effect-ConfigError.esm.js +185 -21
- package/ConfigProvider/dist/effect-ConfigProvider.cjs.dev.js +38 -38
- package/ConfigProvider/dist/effect-ConfigProvider.cjs.prod.js +38 -38
- package/ConfigProvider/dist/effect-ConfigProvider.esm.js +198 -39
- package/ConfigProviderPathPatch/dist/effect-ConfigProviderPathPatch.cjs.dev.js +24 -24
- package/ConfigProviderPathPatch/dist/effect-ConfigProviderPathPatch.cjs.prod.js +24 -24
- package/ConfigProviderPathPatch/dist/effect-ConfigProviderPathPatch.esm.js +70 -24
- package/ConfigSecret/dist/effect-ConfigSecret.cjs.dev.js +22 -22
- package/ConfigSecret/dist/effect-ConfigSecret.cjs.prod.js +22 -22
- package/ConfigSecret/dist/effect-ConfigSecret.esm.js +63 -22
- package/Console/dist/effect-Console.cjs.dev.js +81 -81
- package/Console/dist/effect-Console.cjs.prod.js +81 -81
- package/Console/dist/effect-Console.esm.js +154 -83
- package/Context/dist/effect-Context.cjs.dev.js +17 -17
- package/Context/dist/effect-Context.cjs.prod.js +17 -17
- package/Context/dist/effect-Context.esm.js +295 -17
- package/Data/dist/effect-Data.cjs.dev.js +7 -7
- package/Data/dist/effect-Data.cjs.prod.js +7 -7
- package/Data/dist/effect-Data.esm.js +163 -7
- package/DefaultServices/dist/effect-DefaultServices.cjs.dev.js +40 -40
- package/DefaultServices/dist/effect-DefaultServices.cjs.prod.js +40 -40
- package/DefaultServices/dist/effect-DefaultServices.esm.js +24 -42
- package/Deferred/dist/effect-Deferred.cjs.dev.js +32 -32
- package/Deferred/dist/effect-Deferred.cjs.prod.js +32 -32
- package/Deferred/dist/effect-Deferred.esm.js +206 -33
- package/Differ/dist/effect-Differ.cjs.dev.js +25 -25
- package/Differ/dist/effect-Differ.cjs.prod.js +25 -25
- package/Differ/dist/effect-Differ.esm.js +137 -26
- package/Duration/dist/effect-Duration.cjs.dev.js +17 -16
- package/Duration/dist/effect-Duration.cjs.mjs +1 -0
- package/Duration/dist/effect-Duration.cjs.prod.js +17 -16
- package/Duration/dist/effect-Duration.esm.js +438 -16
- package/Effect/dist/effect-Effect.cjs.dev.js +87 -87
- package/Effect/dist/effect-Effect.cjs.prod.js +87 -87
- package/Effect/dist/effect-Effect.esm.js +3093 -89
- package/Effectable/dist/effect-Effectable.cjs.dev.js +10 -10
- package/Effectable/dist/effect-Effectable.cjs.prod.js +10 -10
- package/Effectable/dist/effect-Effectable.esm.js +77 -10
- package/Either/dist/effect-Either.cjs.dev.js +13 -13
- package/Either/dist/effect-Either.cjs.prod.js +13 -13
- package/Either/dist/effect-Either.esm.js +442 -13
- package/Encoding/dist/effect-Encoding.cjs.dev.js +14 -14
- package/Encoding/dist/effect-Encoding.cjs.prod.js +14 -14
- package/Encoding/dist/effect-Encoding.esm.js +123 -14
- package/Equal/dist/effect-Equal.cjs.dev.js +6 -6
- package/Equal/dist/effect-Equal.cjs.prod.js +6 -6
- package/Equal/dist/effect-Equal.esm.js +57 -6
- package/Equivalence/dist/effect-Equivalence.cjs.dev.js +2 -2
- package/Equivalence/dist/effect-Equivalence.cjs.prod.js +2 -2
- package/Equivalence/dist/effect-Equivalence.esm.js +196 -2
- package/Error/dist/effect-Error.cjs.dev.js +89 -89
- package/Error/dist/effect-Error.cjs.prod.js +89 -89
- package/Error/dist/effect-Error.esm.js +47 -91
- package/ExecutionStrategy/dist/effect-ExecutionStrategy.cjs.dev.js +2 -2
- package/ExecutionStrategy/dist/effect-ExecutionStrategy.cjs.prod.js +2 -2
- package/ExecutionStrategy/dist/effect-ExecutionStrategy.esm.js +99 -2
- package/Exit/dist/effect-Exit.cjs.dev.js +32 -32
- package/Exit/dist/effect-Exit.cjs.prod.js +32 -32
- package/Exit/dist/effect-Exit.esm.js +332 -33
- package/Fiber/dist/effect-Fiber.cjs.dev.js +75 -75
- package/Fiber/dist/effect-Fiber.cjs.prod.js +75 -75
- package/Fiber/dist/effect-Fiber.esm.js +423 -77
- package/FiberId/dist/effect-FiberId.cjs.dev.js +19 -19
- package/FiberId/dist/effect-FiberId.cjs.prod.js +19 -19
- package/FiberId/dist/effect-FiberId.esm.js +161 -20
- package/FiberRef/dist/effect-FiberRef.cjs.dev.js +73 -73
- package/FiberRef/dist/effect-FiberRef.cjs.prod.js +73 -73
- package/FiberRef/dist/effect-FiberRef.esm.js +289 -75
- package/FiberRefs/dist/effect-FiberRefs.cjs.dev.js +33 -33
- package/FiberRefs/dist/effect-FiberRefs.cjs.prod.js +33 -33
- package/FiberRefs/dist/effect-FiberRefs.esm.js +107 -34
- package/FiberRefsPatch/dist/effect-FiberRefsPatch.cjs.dev.js +34 -34
- package/FiberRefsPatch/dist/effect-FiberRefsPatch.cjs.prod.js +34 -34
- package/FiberRefsPatch/dist/effect-FiberRefsPatch.esm.js +76 -35
- package/FiberStatus/dist/effect-FiberStatus.cjs.dev.js +7 -7
- package/FiberStatus/dist/effect-FiberStatus.cjs.prod.js +7 -7
- package/FiberStatus/dist/effect-FiberStatus.esm.js +89 -7
- package/Function/dist/effect-Function.cjs.dev.js +1 -1
- package/Function/dist/effect-Function.cjs.prod.js +1 -1
- package/Function/dist/effect-Function.esm.js +492 -1
- package/GlobalValue/dist/effect-GlobalValue.cjs.dev.js +1 -1
- package/GlobalValue/dist/effect-GlobalValue.cjs.prod.js +1 -1
- package/GlobalValue/dist/effect-GlobalValue.esm.js +20 -1
- package/GroupBy/dist/effect-GroupBy.cjs.dev.js +106 -106
- package/GroupBy/dist/effect-GroupBy.cjs.prod.js +106 -106
- package/GroupBy/dist/effect-GroupBy.esm.js +63 -108
- package/Hash/dist/effect-Hash.cjs.dev.js +5 -5
- package/Hash/dist/effect-Hash.cjs.prod.js +5 -5
- package/Hash/dist/effect-Hash.esm.js +164 -5
- package/HashMap/dist/effect-HashMap.cjs.dev.js +17 -17
- package/HashMap/dist/effect-HashMap.cjs.prod.js +17 -17
- package/HashMap/dist/effect-HashMap.esm.js +287 -18
- package/HashSet/dist/effect-HashSet.cjs.dev.js +17 -17
- package/HashSet/dist/effect-HashSet.cjs.prod.js +17 -17
- package/HashSet/dist/effect-HashSet.esm.js +227 -18
- package/Hub/dist/effect-Hub.cjs.dev.js +72 -72
- package/Hub/dist/effect-Hub.cjs.prod.js +72 -72
- package/Hub/dist/effect-Hub.esm.js +148 -74
- package/Inspectable/dist/effect-Inspectable.cjs.dev.js +1 -1
- package/Inspectable/dist/effect-Inspectable.cjs.prod.js +1 -1
- package/Inspectable/dist/effect-Inspectable.esm.js +38 -1
- package/KeyedPool/dist/effect-KeyedPool.cjs.dev.js +73 -73
- package/KeyedPool/dist/effect-KeyedPool.cjs.prod.js +73 -73
- package/KeyedPool/dist/effect-KeyedPool.esm.js +104 -75
- package/Layer/dist/effect-Layer.cjs.dev.js +81 -81
- package/Layer/dist/effect-Layer.cjs.prod.js +81 -81
- package/Layer/dist/effect-Layer.esm.js +557 -83
- package/List/dist/effect-List.cjs.dev.js +21 -21
- package/List/dist/effect-List.cjs.prod.js +21 -21
- package/List/dist/effect-List.esm.js +816 -21
- package/LogLevel/dist/effect-LogLevel.cjs.dev.js +32 -32
- package/LogLevel/dist/effect-LogLevel.cjs.prod.js +32 -32
- package/LogLevel/dist/effect-LogLevel.esm.js +202 -33
- package/LogSpan/dist/effect-LogSpan.cjs.dev.js +1 -1
- package/LogSpan/dist/effect-LogSpan.cjs.prod.js +1 -1
- package/LogSpan/dist/effect-LogSpan.esm.js +24 -1
- package/Logger/dist/effect-Logger.cjs.dev.js +83 -83
- package/Logger/dist/effect-Logger.cjs.prod.js +83 -83
- package/Logger/dist/effect-Logger.esm.js +198 -85
- package/Metric/dist/effect-Metric.cjs.dev.js +69 -69
- package/Metric/dist/effect-Metric.cjs.prod.js +69 -69
- package/Metric/dist/effect-Metric.esm.js +395 -71
- package/MetricBoundaries/dist/effect-MetricBoundaries.cjs.dev.js +22 -22
- package/MetricBoundaries/dist/effect-MetricBoundaries.cjs.prod.js +22 -22
- package/MetricBoundaries/dist/effect-MetricBoundaries.esm.js +52 -22
- package/MetricHook/dist/effect-MetricHook.cjs.dev.js +26 -26
- package/MetricHook/dist/effect-MetricHook.cjs.prod.js +26 -26
- package/MetricHook/dist/effect-MetricHook.esm.js +68 -27
- package/MetricKey/dist/effect-MetricKey.cjs.dev.js +22 -22
- package/MetricKey/dist/effect-MetricKey.cjs.prod.js +22 -22
- package/MetricKey/dist/effect-MetricKey.esm.js +104 -23
- package/MetricKeyType/dist/effect-MetricKeyType.cjs.dev.js +18 -18
- package/MetricKeyType/dist/effect-MetricKeyType.cjs.prod.js +18 -18
- package/MetricKeyType/dist/effect-MetricKeyType.esm.js +147 -18
- package/MetricLabel/dist/effect-MetricLabel.cjs.dev.js +9 -9
- package/MetricLabel/dist/effect-MetricLabel.cjs.prod.js +9 -9
- package/MetricLabel/dist/effect-MetricLabel.esm.js +41 -9
- package/MetricPair/dist/effect-MetricPair.cjs.dev.js +3 -3
- package/MetricPair/dist/effect-MetricPair.cjs.prod.js +3 -3
- package/MetricPair/dist/effect-MetricPair.esm.js +38 -3
- package/MetricPolling/dist/effect-MetricPolling.cjs.dev.js +75 -75
- package/MetricPolling/dist/effect-MetricPolling.cjs.prod.js +75 -75
- package/MetricPolling/dist/effect-MetricPolling.esm.js +84 -77
- package/MetricRegistry/dist/effect-MetricRegistry.cjs.dev.js +32 -32
- package/MetricRegistry/dist/effect-MetricRegistry.cjs.prod.js +32 -32
- package/MetricRegistry/dist/effect-MetricRegistry.esm.js +28 -33
- package/MetricState/dist/effect-MetricState.cjs.dev.js +9 -9
- package/MetricState/dist/effect-MetricState.cjs.prod.js +9 -9
- package/MetricState/dist/effect-MetricState.esm.js +151 -9
- package/MutableHashMap/dist/effect-MutableHashMap.cjs.dev.js +19 -19
- package/MutableHashMap/dist/effect-MutableHashMap.cjs.prod.js +19 -19
- package/MutableHashMap/dist/effect-MutableHashMap.esm.js +128 -20
- package/MutableHashSet/dist/effect-MutableHashSet.cjs.dev.js +20 -20
- package/MutableHashSet/dist/effect-MutableHashSet.cjs.prod.js +20 -20
- package/MutableHashSet/dist/effect-MutableHashSet.esm.js +90 -21
- package/MutableList/dist/effect-MutableList.cjs.dev.js +4 -4
- package/MutableList/dist/effect-MutableList.cjs.prod.js +4 -4
- package/MutableList/dist/effect-MutableList.esm.js +264 -4
- package/MutableQueue/dist/effect-MutableQueue.cjs.dev.js +22 -22
- package/MutableQueue/dist/effect-MutableQueue.cjs.prod.js +22 -22
- package/MutableQueue/dist/effect-MutableQueue.esm.js +187 -22
- package/MutableRef/dist/effect-MutableRef.cjs.dev.js +9 -9
- package/MutableRef/dist/effect-MutableRef.cjs.prod.js +9 -9
- package/MutableRef/dist/effect-MutableRef.esm.js +156 -9
- package/NonEmptyIterable/dist/effect-NonEmptyIterable.cjs.dev.js +1 -1
- package/NonEmptyIterable/dist/effect-NonEmptyIterable.cjs.prod.js +1 -1
- package/NonEmptyIterable/dist/effect-NonEmptyIterable.esm.js +28 -1
- package/Number/dist/effect-Number.cjs.dev.js +5 -5
- package/Number/dist/effect-Number.cjs.prod.js +5 -5
- package/Number/dist/effect-Number.esm.js +369 -5
- package/Option/dist/effect-Option.cjs.dev.js +15 -15
- package/Option/dist/effect-Option.cjs.prod.js +15 -15
- package/Option/dist/effect-Option.esm.js +1071 -15
- package/Order/dist/effect-Order.cjs.dev.js +2 -2
- package/Order/dist/effect-Order.cjs.prod.js +2 -2
- package/Order/dist/effect-Order.esm.js +263 -2
- package/Ordering/dist/effect-Ordering.cjs.dev.js +2 -2
- package/Ordering/dist/effect-Ordering.cjs.prod.js +2 -2
- package/Ordering/dist/effect-Ordering.esm.js +88 -2
- package/Pipeable/dist/effect-Pipeable.cjs.dev.js +1 -1
- package/Pipeable/dist/effect-Pipeable.cjs.prod.js +1 -1
- package/Pipeable/dist/effect-Pipeable.esm.js +44 -1
- package/Pool/dist/effect-Pool.cjs.dev.js +73 -73
- package/Pool/dist/effect-Pool.cjs.prod.js +73 -73
- package/Pool/dist/effect-Pool.esm.js +104 -75
- package/Predicate/dist/effect-Predicate.cjs.dev.js +2 -2
- package/Predicate/dist/effect-Predicate.cjs.prod.js +2 -2
- package/Predicate/dist/effect-Predicate.esm.js +634 -2
- package/Queue/dist/effect-Queue.cjs.dev.js +72 -72
- package/Queue/dist/effect-Queue.cjs.prod.js +72 -72
- package/Queue/dist/effect-Queue.esm.js +328 -74
- package/Random/dist/effect-Random.cjs.dev.js +40 -40
- package/Random/dist/effect-Random.cjs.prod.js +40 -40
- package/Random/dist/effect-Random.esm.js +83 -42
- package/ReadonlyArray/dist/effect-ReadonlyArray.cjs.dev.js +19 -19
- package/ReadonlyArray/dist/effect-ReadonlyArray.cjs.prod.js +19 -19
- package/ReadonlyArray/dist/effect-ReadonlyArray.esm.js +1445 -19
- package/ReadonlyRecord/dist/effect-ReadonlyRecord.cjs.dev.js +17 -17
- package/ReadonlyRecord/dist/effect-ReadonlyRecord.cjs.prod.js +17 -17
- package/ReadonlyRecord/dist/effect-ReadonlyRecord.esm.js +518 -17
- package/RedBlackTree/dist/effect-RedBlackTree.cjs.dev.js +21 -21
- package/RedBlackTree/dist/effect-RedBlackTree.cjs.prod.js +21 -21
- package/RedBlackTree/dist/effect-RedBlackTree.esm.js +314 -22
- package/Ref/dist/effect-Ref.cjs.dev.js +32 -32
- package/Ref/dist/effect-Ref.cjs.prod.js +32 -32
- package/Ref/dist/effect-Ref.esm.js +111 -33
- package/Reloadable/dist/effect-Reloadable.cjs.dev.js +82 -82
- package/Reloadable/dist/effect-Reloadable.cjs.prod.js +82 -82
- package/Reloadable/dist/effect-Reloadable.esm.js +88 -84
- package/Request/dist/effect-Request.cjs.dev.js +72 -72
- package/Request/dist/effect-Request.cjs.prod.js +72 -72
- package/Request/dist/effect-Request.esm.js +160 -74
- package/RequestBlock/dist/effect-RequestBlock.cjs.dev.js +89 -89
- package/RequestBlock/dist/effect-RequestBlock.cjs.prod.js +89 -89
- package/RequestBlock/dist/effect-RequestBlock.esm.js +103 -91
- package/RequestResolver/dist/effect-RequestResolver.cjs.dev.js +89 -89
- package/RequestResolver/dist/effect-RequestResolver.cjs.prod.js +89 -89
- package/RequestResolver/dist/effect-RequestResolver.esm.js +191 -91
- package/Resource/dist/effect-Resource.cjs.dev.js +77 -77
- package/Resource/dist/effect-Resource.cjs.prod.js +77 -77
- package/Resource/dist/effect-Resource.esm.js +70 -79
- package/Runtime/dist/effect-Runtime.cjs.dev.js +77 -77
- package/Runtime/dist/effect-Runtime.cjs.prod.js +77 -77
- package/Runtime/dist/effect-Runtime.esm.js +157 -79
- package/RuntimeFlags/dist/effect-RuntimeFlags.cjs.dev.js +83 -83
- package/RuntimeFlags/dist/effect-RuntimeFlags.cjs.prod.js +83 -83
- package/RuntimeFlags/dist/effect-RuntimeFlags.esm.js +305 -85
- package/RuntimeFlagsPatch/dist/effect-RuntimeFlagsPatch.cjs.dev.js +26 -26
- package/RuntimeFlagsPatch/dist/effect-RuntimeFlagsPatch.cjs.prod.js +26 -26
- package/RuntimeFlagsPatch/dist/effect-RuntimeFlagsPatch.esm.js +158 -27
- package/STM/dist/effect-STM.cjs.dev.js +110 -110
- package/STM/dist/effect-STM.cjs.prod.js +110 -110
- package/STM/dist/effect-STM.esm.js +1193 -112
- package/Schedule/dist/effect-Schedule.cjs.dev.js +55 -55
- package/Schedule/dist/effect-Schedule.cjs.prod.js +55 -55
- package/Schedule/dist/effect-Schedule.esm.js +957 -57
- package/ScheduleDecision/dist/effect-ScheduleDecision.cjs.dev.js +24 -24
- package/ScheduleDecision/dist/effect-ScheduleDecision.cjs.prod.js +24 -24
- package/ScheduleDecision/dist/effect-ScheduleDecision.esm.js +48 -24
- package/ScheduleInterval/dist/effect-ScheduleInterval.cjs.dev.js +17 -17
- package/ScheduleInterval/dist/effect-ScheduleInterval.cjs.prod.js +17 -17
- package/ScheduleInterval/dist/effect-ScheduleInterval.esm.js +130 -17
- package/ScheduleIntervals/dist/effect-ScheduleIntervals.cjs.dev.js +23 -23
- package/ScheduleIntervals/dist/effect-ScheduleIntervals.cjs.prod.js +23 -23
- package/ScheduleIntervals/dist/effect-ScheduleIntervals.esm.js +105 -23
- package/Scheduler/dist/effect-Scheduler.cjs.dev.js +32 -32
- package/Scheduler/dist/effect-Scheduler.cjs.prod.js +32 -32
- package/Scheduler/dist/effect-Scheduler.esm.js +326 -34
- package/Scope/dist/effect-Scope.cjs.dev.js +69 -69
- package/Scope/dist/effect-Scope.cjs.prod.js +69 -69
- package/Scope/dist/effect-Scope.esm.js +117 -71
- package/ScopedCache/dist/effect-ScopedCache.cjs.dev.js +73 -73
- package/ScopedCache/dist/effect-ScopedCache.cjs.prod.js +73 -73
- package/ScopedCache/dist/effect-ScopedCache.esm.js +52 -75
- package/ScopedRef/dist/effect-ScopedRef.cjs.dev.js +77 -77
- package/ScopedRef/dist/effect-ScopedRef.cjs.prod.js +77 -77
- package/ScopedRef/dist/effect-ScopedRef.esm.js +71 -79
- package/Sink/dist/effect-Sink.cjs.dev.js +99 -99
- package/Sink/dist/effect-Sink.cjs.prod.js +99 -99
- package/Sink/dist/effect-Sink.esm.js +997 -101
- package/SortedMap/dist/effect-SortedMap.cjs.dev.js +22 -22
- package/SortedMap/dist/effect-SortedMap.cjs.prod.js +22 -22
- package/SortedMap/dist/effect-SortedMap.esm.js +168 -23
- package/SortedSet/dist/effect-SortedSet.cjs.dev.js +22 -22
- package/SortedSet/dist/effect-SortedSet.cjs.prod.js +22 -22
- package/SortedSet/dist/effect-SortedSet.esm.js +263 -23
- package/Stream/dist/effect-Stream.cjs.dev.js +106 -106
- package/Stream/dist/effect-Stream.cjs.prod.js +106 -106
- package/Stream/dist/effect-Stream.esm.js +2879 -108
- package/StreamHaltStrategy/dist/effect-StreamHaltStrategy.cjs.dev.js +2 -2
- package/StreamHaltStrategy/dist/effect-StreamHaltStrategy.cjs.prod.js +2 -2
- package/StreamHaltStrategy/dist/effect-StreamHaltStrategy.esm.js +97 -2
- package/String/dist/effect-String.cjs.dev.js +17 -17
- package/String/dist/effect-String.cjs.prod.js +17 -17
- package/String/dist/effect-String.esm.js +600 -17
- package/Struct/dist/effect-Struct.cjs.dev.js +4 -4
- package/Struct/dist/effect-Struct.cjs.prod.js +4 -4
- package/Struct/dist/effect-Struct.esm.js +125 -4
- package/SubscriptionRef/dist/effect-SubscriptionRef.cjs.dev.js +106 -106
- package/SubscriptionRef/dist/effect-SubscriptionRef.cjs.prod.js +106 -106
- package/SubscriptionRef/dist/effect-SubscriptionRef.esm.js +160 -108
- package/Supervisor/dist/effect-Supervisor.cjs.dev.js +83 -83
- package/Supervisor/dist/effect-Supervisor.cjs.prod.js +83 -83
- package/Supervisor/dist/effect-Supervisor.esm.js +148 -85
- package/Symbol/dist/effect-Symbol.cjs.dev.js +4 -4
- package/Symbol/dist/effect-Symbol.cjs.prod.js +4 -4
- package/Symbol/dist/effect-Symbol.esm.js +30 -4
- package/SynchronizedRef/dist/effect-SynchronizedRef.cjs.dev.js +76 -76
- package/SynchronizedRef/dist/effect-SynchronizedRef.cjs.prod.js +76 -76
- package/SynchronizedRef/dist/effect-SynchronizedRef.esm.js +160 -78
- package/TArray/dist/effect-TArray.cjs.dev.js +112 -112
- package/TArray/dist/effect-TArray.cjs.prod.js +112 -112
- package/TArray/dist/effect-TArray.esm.js +367 -114
- package/TDeferred/dist/effect-TDeferred.cjs.dev.js +111 -111
- package/TDeferred/dist/effect-TDeferred.cjs.prod.js +111 -111
- package/TDeferred/dist/effect-TDeferred.esm.js +63 -113
- package/THub/dist/effect-THub.cjs.dev.js +113 -113
- package/THub/dist/effect-THub.cjs.prod.js +113 -113
- package/THub/dist/effect-THub.esm.js +157 -115
- package/TMap/dist/effect-TMap.cjs.dev.js +114 -114
- package/TMap/dist/effect-TMap.cjs.prod.js +114 -114
- package/TMap/dist/effect-TMap.esm.js +373 -116
- package/TPriorityQueue/dist/effect-TPriorityQueue.cjs.dev.js +111 -111
- package/TPriorityQueue/dist/effect-TPriorityQueue.cjs.prod.js +111 -111
- package/TPriorityQueue/dist/effect-TPriorityQueue.esm.js +184 -113
- package/TQueue/dist/effect-TQueue.cjs.dev.js +113 -113
- package/TQueue/dist/effect-TQueue.cjs.prod.js +113 -113
- package/TQueue/dist/effect-TQueue.esm.js +293 -115
- package/TRandom/dist/effect-TRandom.cjs.dev.js +112 -112
- package/TRandom/dist/effect-TRandom.cjs.prod.js +112 -112
- package/TRandom/dist/effect-TRandom.esm.js +93 -114
- package/TReentrantLock/dist/effect-TReentrantLock.cjs.dev.js +110 -110
- package/TReentrantLock/dist/effect-TReentrantLock.cjs.prod.js +110 -110
- package/TReentrantLock/dist/effect-TReentrantLock.esm.js +199 -112
- package/TRef/dist/effect-TRef.cjs.dev.js +110 -110
- package/TRef/dist/effect-TRef.cjs.prod.js +110 -110
- package/TRef/dist/effect-TRef.esm.js +116 -112
- package/TSemaphore/dist/effect-TSemaphore.cjs.dev.js +112 -112
- package/TSemaphore/dist/effect-TSemaphore.cjs.prod.js +112 -112
- package/TSemaphore/dist/effect-TSemaphore.esm.js +97 -114
- package/TSet/dist/effect-TSet.cjs.dev.js +114 -114
- package/TSet/dist/effect-TSet.cjs.prod.js +114 -114
- package/TSet/dist/effect-TSet.esm.js +268 -116
- package/Take/dist/effect-Take.cjs.dev.js +89 -89
- package/Take/dist/effect-Take.cjs.prod.js +89 -89
- package/Take/dist/effect-Take.esm.js +190 -91
- package/TestAnnotation/dist/effect-TestAnnotation.cjs.dev.js +25 -25
- package/TestAnnotation/dist/effect-TestAnnotation.cjs.prod.js +25 -25
- package/TestAnnotation/dist/effect-TestAnnotation.esm.js +111 -26
- package/TestAnnotationMap/dist/effect-TestAnnotationMap.cjs.dev.js +2 -2
- package/TestAnnotationMap/dist/effect-TestAnnotationMap.cjs.prod.js +2 -2
- package/TestAnnotationMap/dist/effect-TestAnnotationMap.esm.js +101 -2
- package/TestAnnotations/dist/effect-TestAnnotations.cjs.dev.js +57 -57
- package/TestAnnotations/dist/effect-TestAnnotations.cjs.prod.js +57 -57
- package/TestAnnotations/dist/effect-TestAnnotations.esm.js +83 -59
- package/TestClock/dist/effect-TestClock.cjs.dev.js +85 -85
- package/TestClock/dist/effect-TestClock.cjs.prod.js +85 -85
- package/TestClock/dist/effect-TestClock.esm.js +411 -87
- package/TestConfig/dist/effect-TestConfig.cjs.dev.js +18 -18
- package/TestConfig/dist/effect-TestConfig.cjs.prod.js +18 -18
- package/TestConfig/dist/effect-TestConfig.esm.js +27 -18
- package/TestContext/dist/effect-TestContext.cjs.dev.js +96 -96
- package/TestContext/dist/effect-TestContext.cjs.prod.js +96 -96
- package/TestContext/dist/effect-TestContext.esm.js +29 -98
- package/TestLive/dist/effect-TestLive.cjs.dev.js +40 -40
- package/TestLive/dist/effect-TestLive.cjs.prod.js +40 -40
- package/TestLive/dist/effect-TestLive.esm.js +48 -42
- package/TestServices/dist/effect-TestServices.cjs.dev.js +94 -94
- package/TestServices/dist/effect-TestServices.cjs.prod.js +94 -94
- package/TestServices/dist/effect-TestServices.esm.js +269 -96
- package/TestSized/dist/effect-TestSized.cjs.dev.js +32 -32
- package/TestSized/dist/effect-TestSized.cjs.prod.js +32 -32
- package/TestSized/dist/effect-TestSized.esm.js +50 -33
- package/Tracer/dist/effect-Tracer.cjs.dev.js +40 -40
- package/Tracer/dist/effect-Tracer.cjs.prod.js +40 -40
- package/Tracer/dist/effect-Tracer.esm.js +68 -42
- package/Tuple/dist/effect-Tuple.cjs.dev.js +4 -4
- package/Tuple/dist/effect-Tuple.cjs.prod.js +4 -4
- package/Tuple/dist/effect-Tuple.esm.js +173 -4
- package/Unify/dist/effect-Unify.cjs.dev.js +2 -2
- package/Unify/dist/effect-Unify.cjs.prod.js +2 -2
- package/Unify/dist/effect-Unify.esm.js +40 -2
- package/Utils/dist/effect-Utils.cjs.dev.js +3 -3
- package/Utils/dist/effect-Utils.cjs.prod.js +3 -3
- package/Utils/dist/effect-Utils.esm.js +352 -3
- package/dist/Bigint-0ebd807c.cjs.dev.js +392 -0
- package/dist/Bigint-912c77f3.cjs.prod.js +392 -0
- package/dist/Boolean-97839b78.cjs.prod.js +264 -0
- package/dist/Boolean-f0bc3abf.cjs.dev.js +264 -0
- package/dist/Brand-93578f43.cjs.prod.js +224 -0
- package/dist/Brand-b238487d.cjs.dev.js +224 -0
- package/dist/Cache-1688e584.cjs.dev.js +127 -0
- package/dist/Cache-8f2f2b55.cjs.prod.js +127 -0
- package/dist/Cause-384e2165.cjs.prod.js +791 -0
- package/dist/Cause-96c29074.cjs.dev.js +791 -0
- package/dist/Channel-2ce019f1.cjs.prod.js +1217 -0
- package/dist/Channel-544108d2.cjs.dev.js +1217 -0
- package/dist/ChannelChildExecutorDecision-168278f6.cjs.prod.js +136 -0
- package/dist/ChannelChildExecutorDecision-b0e715de.cjs.dev.js +136 -0
- package/dist/ChannelMergeDecision-9c266aeb.cjs.prod.js +78 -0
- package/dist/ChannelMergeDecision-eeaf4779.cjs.dev.js +78 -0
- package/dist/ChannelMergeState-4366d090.cjs.prod.js +125 -0
- package/dist/ChannelMergeState-abce1d88.cjs.dev.js +125 -0
- package/dist/ChannelMergeStrategy-6193b8e0.cjs.prod.js +104 -0
- package/dist/ChannelMergeStrategy-e7ddbb7a.cjs.dev.js +104 -0
- package/dist/ChannelSingleProducerAsyncInput-62f4749c.cjs.dev.js +55 -0
- package/dist/ChannelSingleProducerAsyncInput-6e0084c3.cjs.prod.js +55 -0
- package/dist/ChannelUpstreamPullRequest-1ca7d2bd.cjs.dev.js +104 -0
- package/dist/ChannelUpstreamPullRequest-208751c3.cjs.prod.js +104 -0
- package/dist/ChannelUpstreamPullStrategy-266b5a77.cjs.prod.js +103 -0
- package/dist/ChannelUpstreamPullStrategy-ec57dc70.cjs.dev.js +103 -0
- package/dist/Chunk-6cf5a8e6.cjs.prod.js +1248 -0
- package/dist/Chunk-bd290b8e.cjs.dev.js +1248 -0
- package/dist/Clock-09ecce0a.cjs.prod.js +97 -0
- package/dist/Clock-bec722c1.cjs.dev.js +97 -0
- package/dist/Config-85ae6286.cjs.prod.js +393 -0
- package/dist/Config-dc58cf69.cjs.dev.js +393 -0
- package/dist/ConfigError-c1f762d2.cjs.dev.js +225 -0
- package/dist/ConfigError-cee682fa.cjs.prod.js +225 -0
- package/dist/ConfigProvider-8341a5f5.cjs.prod.js +240 -0
- package/dist/ConfigProvider-de45b085.cjs.dev.js +240 -0
- package/dist/ConfigProviderPathPatch-52422b32.cjs.prod.js +86 -0
- package/dist/ConfigProviderPathPatch-d22442e3.cjs.dev.js +86 -0
- package/dist/ConfigSecret-c76717e8.cjs.dev.js +83 -0
- package/dist/ConfigSecret-ebab2ae7.cjs.prod.js +83 -0
- package/dist/Console-150b7b40.cjs.prod.js +271 -0
- package/dist/Console-4825ee9f.cjs.dev.js +271 -0
- package/dist/Context-25a49952.cjs.prod.js +327 -0
- package/dist/Context-3c9e986b.cjs.dev.js +327 -0
- package/dist/Context-96739709.cjs.dev.js +222 -0
- package/dist/Context-f958cabc.cjs.prod.js +222 -0
- package/dist/Data-07dc27f1.cjs.prod.js +237 -0
- package/dist/Data-85559fb3.cjs.dev.js +237 -0
- package/dist/DefaultServices-d5740d37.cjs.dev.js +34 -0
- package/dist/DefaultServices-df7495bb.cjs.prod.js +34 -0
- package/dist/Deferred-5d5c886c.cjs.dev.js +253 -0
- package/dist/Deferred-9d825b3b.cjs.prod.js +253 -0
- package/dist/Differ-0122f60e.cjs.dev.js +992 -0
- package/dist/Differ-0bd34066.cjs.prod.js +992 -0
- package/dist/Duration-0bc08d03.cjs.prod.js +508 -0
- package/dist/Duration-604874d1.cjs.dev.js +508 -0
- package/dist/Effect-1442090f.cjs.prod.js +3740 -0
- package/dist/Effect-6e9780e6.cjs.dev.js +3740 -0
- package/dist/Effectable-04f3cd30.cjs.dev.js +99 -0
- package/dist/Effectable-8997112d.cjs.prod.js +99 -0
- package/dist/Effectable-a6403e5f.cjs.dev.js +181 -0
- package/dist/Effectable-f867d1cb.cjs.prod.js +181 -0
- package/dist/Either-3fab3796.cjs.prod.js +502 -0
- package/dist/Either-9c349424.cjs.dev.js +178 -0
- package/dist/Either-a806809d.cjs.dev.js +502 -0
- package/dist/Either-d03d5f05.cjs.prod.js +178 -0
- package/dist/Encoding-0cab52d5.cjs.prod.js +309 -0
- package/dist/Encoding-d993b1b0.cjs.dev.js +309 -0
- package/dist/Equal-281b6ca8.cjs.dev.js +71 -0
- package/dist/Equal-ce9977a8.cjs.prod.js +71 -0
- package/dist/Equivalence-0bc84518.cjs.prod.js +238 -0
- package/dist/Equivalence-de7a0d51.cjs.dev.js +238 -0
- package/dist/Error-5ab157f2.cjs.dev.js +57 -0
- package/dist/Error-e9d25c53.cjs.prod.js +57 -0
- package/dist/ExecutionStrategy-89fbe735.cjs.dev.js +180 -0
- package/dist/ExecutionStrategy-dc778180.cjs.prod.js +180 -0
- package/dist/Exit-5691142c.cjs.prod.js +408 -0
- package/dist/Exit-a23874e1.cjs.dev.js +408 -0
- package/dist/Fiber-6432d5f7.cjs.dev.js +521 -0
- package/dist/Fiber-e61b3c65.cjs.prod.js +521 -0
- package/dist/FiberId-929dcce4.cjs.dev.js +443 -0
- package/dist/FiberId-b79e8047.cjs.prod.js +443 -0
- package/dist/FiberRef-1db44a9b.cjs.dev.js +385 -0
- package/dist/FiberRef-efb4a3ac.cjs.prod.js +385 -0
- package/dist/FiberRefs-43bfd8b9.cjs.dev.js +135 -0
- package/dist/FiberRefs-4cb171f7.cjs.prod.js +135 -0
- package/dist/FiberRefsPatch-5236f61e.cjs.dev.js +90 -0
- package/dist/FiberRefsPatch-cb847553.cjs.prod.js +90 -0
- package/dist/FiberStatus-b82dad24.cjs.prod.js +197 -0
- package/dist/FiberStatus-bac7d58d.cjs.dev.js +197 -0
- package/dist/Function-2e6b0cda.cjs.prod.js +538 -0
- package/dist/Function-41ce433d.cjs.dev.js +538 -0
- package/dist/GlobalValue-81ab6908.cjs.dev.js +28 -0
- package/dist/GlobalValue-cb645c99.cjs.prod.js +28 -0
- package/dist/GroupBy-8a8149b4.cjs.dev.js +79 -0
- package/dist/GroupBy-b74084af.cjs.prod.js +79 -0
- package/dist/Hash-1bd73210.cjs.prod.js +192 -0
- package/dist/Hash-bd154268.cjs.dev.js +192 -0
- package/dist/HashMap-12668911.cjs.prod.js +361 -0
- package/dist/HashMap-68e290b6.cjs.dev.js +361 -0
- package/dist/HashSet-6978c08e.cjs.dev.js +283 -0
- package/dist/HashSet-6fe62df2.cjs.prod.js +965 -0
- package/dist/HashSet-c40a52b1.cjs.prod.js +283 -0
- package/dist/HashSet-ece2cfe8.cjs.dev.js +965 -0
- package/dist/Hub-6e64debd.cjs.prod.js +1280 -0
- package/dist/Hub-74834668.cjs.dev.js +1280 -0
- package/dist/Inspectable-3c4a0f5d.cjs.prod.js +50 -0
- package/dist/Inspectable-ac929af4.cjs.dev.js +50 -0
- package/dist/KeyedPool-b05481e9.cjs.dev.js +282 -0
- package/dist/KeyedPool-cd8abf95.cjs.prod.js +282 -0
- package/dist/Layer-297269fd.cjs.prod.js +687 -0
- package/dist/Layer-c69f3fdc.cjs.dev.js +687 -0
- package/dist/List-c6ea7efe.cjs.dev.js +912 -0
- package/dist/List-d9775087.cjs.prod.js +912 -0
- package/dist/LogLevel-99f64f82.cjs.dev.js +240 -0
- package/dist/LogLevel-e9848e15.cjs.prod.js +240 -0
- package/dist/LogSpan-c905a192.cjs.prod.js +46 -0
- package/dist/LogSpan-e345ba58.cjs.dev.js +46 -0
- package/dist/Logger-680763c7.cjs.dev.js +275 -0
- package/dist/Logger-7a664cc3.cjs.prod.js +275 -0
- package/dist/Metric-09d012ff.cjs.dev.js +488 -0
- package/dist/Metric-b7563a68.cjs.prod.js +488 -0
- package/dist/MetricBoundaries-cf5df220.cjs.prod.js +68 -0
- package/dist/MetricBoundaries-f5f5aae1.cjs.dev.js +68 -0
- package/dist/MetricHook-3104e93b.cjs.dev.js +90 -0
- package/dist/MetricHook-efd05d72.cjs.prod.js +90 -0
- package/dist/MetricKey-9cfcaec8.cjs.prod.js +130 -0
- package/dist/MetricKey-c3ba437e.cjs.dev.js +130 -0
- package/dist/MetricKeyType-6d2d9036.cjs.prod.js +187 -0
- package/dist/MetricKeyType-c1d7ebe8.cjs.dev.js +187 -0
- package/dist/MetricLabel-6a1886c6.cjs.dev.js +53 -0
- package/dist/MetricLabel-7e1d569e.cjs.prod.js +53 -0
- package/dist/MetricPair-658ab13d.cjs.dev.js +50 -0
- package/dist/MetricPair-aec13967.cjs.prod.js +50 -0
- package/dist/MetricPolling-5af0ff67.cjs.dev.js +177 -0
- package/dist/MetricPolling-a0a4e798.cjs.prod.js +177 -0
- package/dist/MetricRegistry-e4af936b.cjs.dev.js +38 -0
- package/dist/MetricRegistry-ff6df283.cjs.prod.js +38 -0
- package/dist/MetricState-b65340a4.cjs.dev.js +191 -0
- package/dist/MetricState-bd6a5001.cjs.prod.js +191 -0
- package/dist/MutableHashMap-74e83e84.cjs.dev.js +154 -0
- package/dist/MutableHashMap-95493edb.cjs.prod.js +154 -0
- package/dist/MutableHashSet-780dfd63.cjs.prod.js +110 -0
- package/dist/MutableHashSet-ec8d7cc4.cjs.dev.js +110 -0
- package/dist/MutableList-58124ef2.cjs.dev.js +296 -0
- package/dist/MutableList-732af09a.cjs.prod.js +296 -0
- package/dist/MutableQueue-0e9f2466.cjs.dev.js +215 -0
- package/dist/MutableQueue-f8aba856.cjs.prod.js +215 -0
- package/dist/MutableRef-4a2f1f23.cjs.prod.js +194 -0
- package/dist/MutableRef-724c4082.cjs.dev.js +194 -0
- package/dist/NonEmptyIterable-418cef14.cjs.prod.js +36 -0
- package/dist/NonEmptyIterable-bb452f41.cjs.dev.js +36 -0
- package/dist/Number-588f6483.cjs.dev.js +417 -0
- package/dist/Number-cb2ba2e8.cjs.prod.js +417 -0
- package/dist/Option-02025c86.cjs.prod.js +1198 -0
- package/dist/Option-03997d77.cjs.dev.js +1198 -0
- package/dist/Order-28bdebd2.cjs.dev.js +321 -0
- package/dist/Order-8a112bfb.cjs.prod.js +321 -0
- package/dist/Ordering-60bf9127.cjs.prod.js +104 -0
- package/dist/Ordering-b955b746.cjs.dev.js +104 -0
- package/dist/Pipeable-4698db72.cjs.dev.js +52 -0
- package/dist/Pipeable-d3ec6711.cjs.prod.js +52 -0
- package/dist/Pool-54389592.cjs.prod.js +122 -0
- package/dist/Pool-fe1b506a.cjs.dev.js +122 -0
- package/dist/Predicate-9e859c9c.cjs.dev.js +718 -0
- package/dist/Predicate-daa86e61.cjs.prod.js +718 -0
- package/dist/Queue-5f954287.cjs.prod.js +394 -0
- package/dist/Queue-8d082fe4.cjs.dev.js +394 -0
- package/dist/Random-35304046.cjs.dev.js +104 -0
- package/dist/Random-b4709b6a.cjs.prod.js +104 -0
- package/dist/ReadonlyArray-48949ee7.cjs.dev.js +1721 -0
- package/dist/ReadonlyArray-8157f697.cjs.prod.js +1721 -0
- package/dist/ReadonlyArray-9a1474f6.cjs.dev.js +10 -0
- package/dist/ReadonlyArray-f9ed7a05.cjs.prod.js +10 -0
- package/dist/ReadonlyRecord-605a625b.cjs.dev.js +568 -0
- package/dist/ReadonlyRecord-8db8bada.cjs.prod.js +568 -0
- package/dist/RedBlackTree-e6bd147c.cjs.dev.js +1669 -0
- package/dist/RedBlackTree-eb41ea8a.cjs.prod.js +1669 -0
- package/dist/Ref-30e5ee58.cjs.prod.js +282 -0
- package/dist/Ref-af783b72.cjs.dev.js +282 -0
- package/dist/Reloadable-2b8ba75d.cjs.prod.js +169 -0
- package/dist/Reloadable-b01c9297.cjs.dev.js +169 -0
- package/dist/Request-53592fe4.cjs.prod.js +190 -0
- package/dist/Request-d3b63af6.cjs.dev.js +190 -0
- package/dist/RequestBlock-1aa4c3bd.cjs.dev.js +124 -0
- package/dist/RequestBlock-8c3b51d1.cjs.prod.js +124 -0
- package/dist/RequestResolver-133197d5.cjs.prod.js +233 -0
- package/dist/RequestResolver-86c21b80.cjs.dev.js +233 -0
- package/dist/Resource-2530fe45.cjs.prod.js +118 -0
- package/dist/Resource-e50b4b25.cjs.dev.js +118 -0
- package/dist/Runtime-0d643f0c.cjs.prod.js +191 -0
- package/dist/Runtime-c4b887ff.cjs.dev.js +191 -0
- package/dist/RuntimeFlags-9d8fac5a.cjs.prod.js +381 -0
- package/dist/RuntimeFlags-f67e3984.cjs.dev.js +381 -0
- package/dist/RuntimeFlagsPatch-130e990c.cjs.dev.js +411 -0
- package/dist/RuntimeFlagsPatch-5570758d.cjs.prod.js +411 -0
- package/dist/STM-23270be2.cjs.prod.js +1447 -0
- package/dist/STM-5a4c9921.cjs.dev.js +1447 -0
- package/dist/Schedule-0444792d.cjs.prod.js +1159 -0
- package/dist/Schedule-b6c7b49a.cjs.dev.js +1159 -0
- package/dist/ScheduleDecision-369f2d2b.cjs.prod.js +106 -0
- package/dist/ScheduleDecision-ba8d0e87.cjs.dev.js +106 -0
- package/dist/ScheduleInterval-51f42533.cjs.dev.js +244 -0
- package/dist/ScheduleInterval-78037484.cjs.prod.js +244 -0
- package/dist/ScheduleIntervals-b0bfcf3b.cjs.dev.js +265 -0
- package/dist/ScheduleIntervals-db13140c.cjs.prod.js +265 -0
- package/dist/Scheduler-819ee02a.cjs.prod.js +358 -0
- package/dist/Scheduler-d080442d.cjs.dev.js +358 -0
- package/dist/Scope-311c7eb9.cjs.prod.js +143 -0
- package/dist/Scope-6ba9ec6d.cjs.dev.js +143 -0
- package/dist/ScopedCache-3f58b125.cjs.dev.js +467 -0
- package/dist/ScopedCache-8f99505c.cjs.prod.js +467 -0
- package/dist/ScopedRef-7946d287.cjs.prod.js +87 -0
- package/dist/ScopedRef-b92e1633.cjs.dev.js +87 -0
- package/dist/Sink-9f13da17.cjs.dev.js +1215 -0
- package/dist/Sink-9f82fc3b.cjs.prod.js +1215 -0
- package/dist/SortedMap-bb3311c3.cjs.prod.js +210 -0
- package/dist/SortedMap-f452cc44.cjs.dev.js +210 -0
- package/dist/SortedSet-424670fe.cjs.prod.js +311 -0
- package/dist/SortedSet-f90b14a2.cjs.dev.js +311 -0
- package/dist/Stream-14325ecb.cjs.dev.js +3469 -0
- package/dist/Stream-cf262c16.cjs.prod.js +3469 -0
- package/dist/StreamHaltStrategy-07f544a6.cjs.prod.js +214 -0
- package/dist/StreamHaltStrategy-66a53f66.cjs.dev.js +214 -0
- package/dist/String-23b18ca9.cjs.prod.js +694 -0
- package/dist/String-830aaa3e.cjs.dev.js +694 -0
- package/dist/Struct-14648d76.cjs.dev.js +141 -0
- package/dist/Struct-c6b00f29.cjs.prod.js +141 -0
- package/dist/SubscriptionRef-aa7bdc5f.cjs.prod.js +269 -0
- package/dist/SubscriptionRef-d3c1aa07.cjs.dev.js +269 -0
- package/dist/Supervisor-21087253.cjs.prod.js +170 -0
- package/dist/Supervisor-40dd7ce5.cjs.dev.js +170 -0
- package/dist/Symbol-55d0b3d8.cjs.prod.js +40 -0
- package/dist/Symbol-5d74a5f2.cjs.dev.js +40 -0
- package/dist/SynchronizedRef-3181eb0a.cjs.dev.js +212 -0
- package/dist/SynchronizedRef-c6e0884b.cjs.prod.js +212 -0
- package/dist/TArray-6767b4bd.cjs.prod.js +455 -0
- package/dist/TArray-a0a4c6e6.cjs.dev.js +455 -0
- package/dist/TDeferred-a9839479.cjs.prod.js +129 -0
- package/dist/TDeferred-ac2c4025.cjs.dev.js +129 -0
- package/dist/THub-25b77864.cjs.prod.js +570 -0
- package/dist/THub-38053ae1.cjs.dev.js +570 -0
- package/dist/TMap-91505efa.cjs.prod.js +463 -0
- package/dist/TMap-de8ac080.cjs.dev.js +463 -0
- package/dist/TPriorityQueue-00b65d1a.cjs.prod.js +381 -0
- package/dist/TPriorityQueue-96ff0e15.cjs.dev.js +381 -0
- package/dist/TQueue-5e242ca2.cjs.prod.js +353 -0
- package/dist/TQueue-707762bf.cjs.dev.js +353 -0
- package/dist/TRandom-5eb21d23.cjs.dev.js +203 -0
- package/dist/TRandom-ec9c7bf7.cjs.prod.js +203 -0
- package/dist/TReentrantLock-1b77d76f.cjs.dev.js +456 -0
- package/dist/TReentrantLock-c5a8401e.cjs.prod.js +456 -0
- package/dist/TRef-b87580d7.cjs.prod.js +152 -0
- package/dist/TRef-cf2e8ad7.cjs.dev.js +152 -0
- package/dist/TSemaphore-29503416.cjs.prod.js +197 -0
- package/dist/TSemaphore-50edec08.cjs.dev.js +197 -0
- package/dist/TSet-3c2568e9.cjs.prod.js +444 -0
- package/dist/TSet-bb4775ca.cjs.dev.js +444 -0
- package/dist/Take-684c9901.cjs.dev.js +236 -0
- package/dist/Take-b4c91438.cjs.prod.js +236 -0
- package/dist/TestAnnotation-73be7a68.cjs.dev.js +135 -0
- package/dist/TestAnnotation-b9b93d03.cjs.prod.js +135 -0
- package/dist/TestAnnotationMap-80c87410.cjs.dev.js +125 -0
- package/dist/TestAnnotationMap-e946bab5.cjs.prod.js +125 -0
- package/dist/TestAnnotations-5db95828.cjs.prod.js +97 -0
- package/dist/TestAnnotations-733b39ef.cjs.dev.js +97 -0
- package/dist/TestClock-89a36b89.cjs.prod.js +581 -0
- package/dist/TestClock-e2773846.cjs.dev.js +581 -0
- package/dist/TestConfig-1a73e844.cjs.prod.js +37 -0
- package/dist/TestConfig-e5ffa946.cjs.dev.js +37 -0
- package/dist/TestContext-3328163e.cjs.dev.js +41 -0
- package/dist/TestContext-917bf305.cjs.prod.js +41 -0
- package/dist/TestLive-465ad3ef.cjs.dev.js +60 -0
- package/dist/TestLive-f3232ac4.cjs.prod.js +60 -0
- package/dist/TestServices-605f726e.cjs.prod.js +341 -0
- package/dist/TestServices-921e5c42.cjs.dev.js +341 -0
- package/dist/TestSized-6c1abc21.cjs.dev.js +64 -0
- package/dist/TestSized-a9a87d64.cjs.prod.js +64 -0
- package/dist/Tracer-d06d0b61.cjs.prod.js +81 -0
- package/dist/Tracer-da182c8c.cjs.dev.js +81 -0
- package/dist/Tuple-27ecf3a1.cjs.prod.js +199 -0
- package/dist/Tuple-75d2a389.cjs.dev.js +199 -0
- package/dist/Unify-99be0499.cjs.dev.js +48 -0
- package/dist/Unify-e86fd412.cjs.prod.js +48 -0
- package/dist/Utils-864e1d48.cjs.prod.js +370 -0
- package/dist/Utils-b0c14d1b.cjs.dev.js +370 -0
- package/dist/boundaries-03c7494a.cjs.dev.js +54 -0
- package/dist/boundaries-5d1a46e1.cjs.prod.js +54 -0
- package/dist/cache-6cdc31f7.cjs.dev.js +523 -0
- package/dist/cache-ab7bbfbd.cjs.prod.js +523 -0
- package/dist/childExecutorDecision-2b30946c.cjs.prod.js +98 -0
- package/dist/childExecutorDecision-ad3db696.cjs.dev.js +98 -0
- package/dist/circular-4cb0b79d.cjs.dev.js +341 -0
- package/dist/circular-5b3558d9.cjs.prod.js +341 -0
- package/dist/circular-78011d6b.cjs.dev.js +107 -0
- package/dist/circular-81b4c556.cjs.prod.js +107 -0
- package/dist/config-10f2a1d1.cjs.dev.js +474 -0
- package/dist/config-78feb1ac.cjs.prod.js +474 -0
- package/dist/configError-1686533e.cjs.dev.js +323 -0
- package/dist/configError-6a3652f8.cjs.prod.js +323 -0
- package/dist/configProvider-2b177eac.cjs.prod.js +447 -0
- package/dist/configProvider-e2eb112d.cjs.dev.js +447 -0
- package/dist/configSecret-5812fa69.cjs.dev.js +74 -0
- package/dist/configSecret-ecb6c5b3.cjs.prod.js +74 -0
- package/dist/core-4ced6e17.cjs.prod.js +1072 -0
- package/dist/core-ac668be0.cjs.dev.js +3502 -0
- package/dist/core-c2eb171a.cjs.prod.js +3502 -0
- package/dist/core-d9eea905.cjs.dev.js +1072 -0
- package/dist/core-effect-a9b8ee08.cjs.dev.js +1030 -0
- package/dist/core-effect-bf806dd9.cjs.prod.js +1030 -0
- package/dist/dataSource-abccc876.cjs.prod.js +74 -0
- package/dist/dataSource-d5f79f4e.cjs.dev.js +74 -0
- package/dist/declarations/src/Bigint.d.ts +22 -22
- package/dist/declarations/src/Boolean.d.ts +15 -15
- package/dist/declarations/src/Brand.d.ts +20 -20
- package/dist/declarations/src/Cache.d.ts +14 -14
- package/dist/declarations/src/Cause.d.ts +81 -81
- package/dist/declarations/src/Channel.d.ts +117 -117
- package/dist/declarations/src/ChannelChildExecutorDecision.d.ts +16 -16
- package/dist/declarations/src/ChannelMergeDecision.d.ts +11 -11
- package/dist/declarations/src/ChannelMergeState.d.ts +17 -17
- package/dist/declarations/src/ChannelMergeStrategy.d.ts +13 -13
- package/dist/declarations/src/ChannelSingleProducerAsyncInput.d.ts +5 -5
- package/dist/declarations/src/ChannelUpstreamPullRequest.d.ts +13 -13
- package/dist/declarations/src/ChannelUpstreamPullStrategy.d.ts +13 -13
- package/dist/declarations/src/Chunk.d.ts +84 -84
- package/dist/declarations/src/Clock.d.ts +13 -13
- package/dist/declarations/src/Config.d.ts +40 -40
- package/dist/declarations/src/ConfigError.d.ts +31 -31
- package/dist/declarations/src/ConfigProvider.d.ts +27 -27
- package/dist/declarations/src/ConfigProviderPathPatch.d.ts +11 -11
- package/dist/declarations/src/ConfigSecret.d.ts +12 -12
- package/dist/declarations/src/Console.d.ts +26 -26
- package/dist/declarations/src/Context.d.ts +24 -24
- package/dist/declarations/src/Data.d.ts +22 -22
- package/dist/declarations/src/DefaultServices.d.ts +4 -4
- package/dist/declarations/src/Deferred.d.ts +26 -26
- package/dist/declarations/src/Differ.d.ts +34 -34
- package/dist/declarations/src/Duration.d.ts +42 -37
- package/dist/declarations/src/Duration.d.ts.map +1 -1
- package/dist/declarations/src/Effect.d.ts +351 -351
- package/dist/declarations/src/Effectable.d.ts +16 -16
- package/dist/declarations/src/Either.d.ts +35 -35
- package/dist/declarations/src/Encoding.d.ts +15 -15
- package/dist/declarations/src/Equal.d.ts +6 -6
- package/dist/declarations/src/Equivalence.d.ts +20 -20
- package/dist/declarations/src/Error.d.ts +4 -4
- package/dist/declarations/src/ExecutionStrategy.d.ts +12 -12
- package/dist/declarations/src/Exit.d.ts +41 -41
- package/dist/declarations/src/Fiber.d.ts +57 -57
- package/dist/declarations/src/FiberId.d.ts +23 -23
- package/dist/declarations/src/FiberRef.d.ts +49 -49
- package/dist/declarations/src/FiberRefs.d.ts +14 -14
- package/dist/declarations/src/FiberRefsPatch.d.ts +11 -11
- package/dist/declarations/src/FiberStatus.d.ts +14 -14
- package/dist/declarations/src/Function.d.ts +24 -24
- package/dist/declarations/src/GlobalValue.d.ts +1 -1
- package/dist/declarations/src/GroupBy.d.ts +9 -9
- package/dist/declarations/src/HKT.d.ts +5 -5
- package/dist/declarations/src/Hash.d.ts +12 -12
- package/dist/declarations/src/HashMap.d.ts +37 -37
- package/dist/declarations/src/HashSet.d.ts +28 -28
- package/dist/declarations/src/Hub.d.ts +16 -16
- package/dist/declarations/src/Inspectable.d.ts +6 -6
- package/dist/declarations/src/KeyedPool.d.ts +12 -12
- package/dist/declarations/src/Layer.d.ts +70 -70
- package/dist/declarations/src/List.d.ts +50 -50
- package/dist/declarations/src/LogLevel.d.ts +27 -27
- package/dist/declarations/src/LogSpan.d.ts +3 -3
- package/dist/declarations/src/Logger.d.ts +33 -33
- package/dist/declarations/src/Metric.d.ts +55 -55
- package/dist/declarations/src/MetricBoundaries.d.ts +8 -8
- package/dist/declarations/src/MetricHook.d.ts +20 -20
- package/dist/declarations/src/MetricKey.d.ts +21 -21
- package/dist/declarations/src/MetricKeyType.d.ts +35 -35
- package/dist/declarations/src/MetricLabel.d.ts +6 -6
- package/dist/declarations/src/MetricPair.d.ts +8 -8
- package/dist/declarations/src/MetricPolling.d.ts +11 -11
- package/dist/declarations/src/MetricRegistry.d.ts +5 -5
- package/dist/declarations/src/MetricState.d.ts +33 -33
- package/dist/declarations/src/MutableHashMap.d.ts +12 -12
- package/dist/declarations/src/MutableHashSet.d.ts +9 -9
- package/dist/declarations/src/MutableList.d.ts +13 -13
- package/dist/declarations/src/MutableQueue.d.ts +16 -16
- package/dist/declarations/src/MutableRef.d.ts +18 -18
- package/dist/declarations/src/NonEmptyIterable.d.ts +4 -4
- package/dist/declarations/src/Number.d.ts +22 -22
- package/dist/declarations/src/Option.d.ts +69 -69
- package/dist/declarations/src/Order.d.ts +28 -28
- package/dist/declarations/src/Ordering.d.ts +7 -7
- package/dist/declarations/src/Pipeable.d.ts +3 -3
- package/dist/declarations/src/Pool.d.ts +11 -11
- package/dist/declarations/src/Predicate.d.ts +42 -42
- package/dist/declarations/src/Queue.d.ts +44 -44
- package/dist/declarations/src/Random.d.ts +11 -11
- package/dist/declarations/src/ReadonlyArray.d.ts +139 -139
- package/dist/declarations/src/ReadonlyRecord.d.ts +25 -25
- package/dist/declarations/src/RedBlackTree.d.ts +40 -40
- package/dist/declarations/src/Ref.d.ts +20 -20
- package/dist/declarations/src/Reloadable.d.ts +13 -13
- package/dist/declarations/src/Request.d.ts +29 -29
- package/dist/declarations/src/RequestBlock.d.ts +16 -16
- package/dist/declarations/src/RequestResolver.d.ts +23 -23
- package/dist/declarations/src/Resource.d.ts +10 -10
- package/dist/declarations/src/Runtime.d.ts +22 -22
- package/dist/declarations/src/RuntimeFlags.d.ts +38 -38
- package/dist/declarations/src/RuntimeFlagsPatch.d.ts +18 -18
- package/dist/declarations/src/STM.d.ts +140 -140
- package/dist/declarations/src/Schedule.d.ts +106 -106
- package/dist/declarations/src/ScheduleDecision.d.ts +8 -8
- package/dist/declarations/src/ScheduleInterval.d.ts +16 -16
- package/dist/declarations/src/ScheduleIntervals.d.ts +14 -14
- package/dist/declarations/src/Scheduler.d.ts +34 -34
- package/dist/declarations/src/Scope.d.ts +18 -18
- package/dist/declarations/src/ScopedCache.d.ts +9 -9
- package/dist/declarations/src/ScopedRef.d.ts +10 -10
- package/dist/declarations/src/Sink.d.ts +115 -115
- package/dist/declarations/src/SortedMap.d.ts +21 -21
- package/dist/declarations/src/SortedSet.d.ts +24 -24
- package/dist/declarations/src/Stream.d.ts +303 -303
- package/dist/declarations/src/StreamEmit.d.ts +3 -3
- package/dist/declarations/src/StreamHaltStrategy.d.ts +16 -16
- package/dist/declarations/src/String.d.ts +50 -50
- package/dist/declarations/src/Struct.d.ts +6 -6
- package/dist/declarations/src/SubscriptionRef.d.ts +27 -27
- package/dist/declarations/src/Supervisor.d.ts +23 -23
- package/dist/declarations/src/Symbol.d.ts +3 -3
- package/dist/declarations/src/SynchronizedRef.d.ts +28 -28
- package/dist/declarations/src/TArray.d.ts +46 -46
- package/dist/declarations/src/TDeferred.d.ts +12 -12
- package/dist/declarations/src/THub.d.ts +18 -18
- package/dist/declarations/src/TMap.d.ts +46 -46
- package/dist/declarations/src/TPriorityQueue.d.ts +23 -23
- package/dist/declarations/src/TQueue.d.ts +36 -36
- package/dist/declarations/src/TRandom.d.ts +12 -12
- package/dist/declarations/src/TReentrantLock.d.ts +24 -24
- package/dist/declarations/src/TRef.d.ts +19 -19
- package/dist/declarations/src/TSemaphore.d.ts +17 -17
- package/dist/declarations/src/TSet.d.ts +35 -35
- package/dist/declarations/src/Take.d.ts +25 -25
- package/dist/declarations/src/TestAnnotation.d.ts +12 -12
- package/dist/declarations/src/TestAnnotationMap.d.ts +11 -11
- package/dist/declarations/src/TestAnnotations.d.ts +7 -7
- package/dist/declarations/src/TestClock.d.ts +16 -16
- package/dist/declarations/src/TestConfig.d.ts +4 -4
- package/dist/declarations/src/TestContext.d.ts +3 -3
- package/dist/declarations/src/TestLive.d.ts +6 -6
- package/dist/declarations/src/TestServices.d.ts +35 -35
- package/dist/declarations/src/TestSized.d.ts +7 -7
- package/dist/declarations/src/Tracer.d.ts +13 -13
- package/dist/declarations/src/Tuple.d.ts +12 -12
- package/dist/declarations/src/Types.d.ts +10 -10
- package/dist/declarations/src/Unify.d.ts +9 -9
- package/dist/declarations/src/Utils.d.ts +29 -29
- package/dist/declarations/src/index.d.ts +169 -141
- package/dist/declarations/src/index.d.ts.map +1 -1
- package/dist/defaultServices-4112c0c9.cjs.prod.js +388 -0
- package/dist/defaultServices-60c753dc.cjs.dev.js +388 -0
- package/dist/effect.cjs.dev.js +199 -193
- package/dist/effect.cjs.mjs +7 -1
- package/dist/effect.cjs.prod.js +199 -193
- package/dist/effect.esm.js +283 -197
- package/dist/fiber-90ffaf8c.cjs.prod.js +411 -0
- package/dist/fiber-da1a207c.cjs.dev.js +411 -0
- package/dist/fiberRefs-64c35250.cjs.prod.js +181 -0
- package/dist/fiberRefs-a7e00f7e.cjs.dev.js +181 -0
- package/dist/fiberRuntime-1c369a47.cjs.prod.js +3012 -0
- package/dist/fiberRuntime-e9680313.cjs.dev.js +3012 -0
- package/dist/groupBy-0cc85afb.cjs.prod.js +216 -0
- package/dist/groupBy-b204a881.cjs.dev.js +216 -0
- package/dist/hook-6c7550dc.cjs.prod.js +371 -0
- package/dist/hook-822704ea.cjs.dev.js +371 -0
- package/dist/key-330b98b1.cjs.prod.js +79 -0
- package/dist/key-a474fc0d.cjs.dev.js +79 -0
- package/dist/keyType-1e916ae2.cjs.dev.js +236 -0
- package/dist/keyType-8460e792.cjs.prod.js +236 -0
- package/dist/label-246fb11d.cjs.dev.js +44 -0
- package/dist/label-3e143765.cjs.prod.js +44 -0
- package/dist/layer-ae8eefad.cjs.dev.js +658 -0
- package/dist/layer-ffacc2c5.cjs.prod.js +658 -0
- package/dist/mergeDecision-e457a76b.cjs.dev.js +86 -0
- package/dist/mergeDecision-e483c280.cjs.prod.js +86 -0
- package/dist/mergeState-83204f38.cjs.dev.js +109 -0
- package/dist/mergeState-dba66248.cjs.prod.js +109 -0
- package/dist/mergeStrategy-845a1279.cjs.prod.js +72 -0
- package/dist/mergeStrategy-b19dc19a.cjs.dev.js +72 -0
- package/dist/pair-08a8685e.cjs.dev.js +42 -0
- package/dist/pair-e5443c93.cjs.prod.js +42 -0
- package/dist/patch-4671ab7f.cjs.dev.js +132 -0
- package/dist/patch-f27e9f08.cjs.prod.js +132 -0
- package/dist/pathPatch-ded405f6.cjs.prod.js +90 -0
- package/dist/pathPatch-e46d4168.cjs.dev.js +90 -0
- package/dist/pool-3f16af61.cjs.dev.js +278 -0
- package/dist/pool-59a31f55.cjs.prod.js +278 -0
- package/dist/query-193d0a89.cjs.dev.js +104 -0
- package/dist/query-fe4a82d6.cjs.prod.js +104 -0
- package/dist/queue-04ae7ec7.cjs.dev.js +538 -0
- package/dist/queue-b81aee38.cjs.prod.js +538 -0
- package/dist/registry-29905dcc.cjs.prod.js +114 -0
- package/dist/registry-c883cf52.cjs.dev.js +114 -0
- package/dist/runtime-3ae98f19.cjs.dev.js +288 -0
- package/dist/runtime-8c3f1bd3.cjs.prod.js +288 -0
- package/dist/schedule-479d8fcc.cjs.dev.js +956 -0
- package/dist/schedule-7e30db2d.cjs.prod.js +956 -0
- package/dist/scopedRef-16d9d192.cjs.dev.js +55 -0
- package/dist/scopedRef-40b5bb82.cjs.prod.js +55 -0
- package/dist/singleProducerAsyncInput-552122e6.cjs.dev.js +193 -0
- package/dist/singleProducerAsyncInput-c5ff73b7.cjs.prod.js +193 -0
- package/dist/sink-16a1a901.cjs.dev.js +3094 -0
- package/dist/sink-c9ae7558.cjs.prod.js +3094 -0
- package/dist/state-0d29362f.cjs.prod.js +227 -0
- package/dist/state-8a8a647c.cjs.dev.js +227 -0
- package/dist/stm-44f045e5.cjs.dev.js +678 -0
- package/dist/stm-59af7e62.cjs.prod.js +678 -0
- package/dist/stream-84a13e23.cjs.dev.js +3645 -0
- package/dist/stream-8acbee57.cjs.prod.js +3645 -0
- package/dist/synchronizedRef-58a64ffe.cjs.dev.js +62 -0
- package/dist/synchronizedRef-6cfe9354.cjs.prod.js +62 -0
- package/dist/tArray-a690480d.cjs.prod.js +330 -0
- package/dist/tArray-c0a3d1e2.cjs.dev.js +330 -0
- package/dist/tMap-1c1b10c4.cjs.dev.js +535 -0
- package/dist/tMap-8dfc92f5.cjs.prod.js +535 -0
- package/dist/tQueue-48a29f8b.cjs.prod.js +367 -0
- package/dist/tQueue-aaec000f.cjs.dev.js +367 -0
- package/dist/tRef-1df89632.cjs.dev.js +133 -0
- package/dist/tRef-cc473a9f.cjs.prod.js +133 -0
- package/dist/take-906e6ef4.cjs.prod.js +152 -0
- package/dist/take-e1c6b82a.cjs.dev.js +152 -0
- package/dist/upstreamPullRequest-705e868d.cjs.prod.js +79 -0
- package/dist/upstreamPullRequest-c08f06a4.cjs.dev.js +79 -0
- package/dist/upstreamPullStrategy-0ccf2960.cjs.dev.js +81 -0
- package/dist/upstreamPullStrategy-34452db1.cjs.prod.js +81 -0
- package/internal/Context.esm.js +208 -0
- package/internal/Data.esm.js +49 -0
- package/internal/Differ/ChunkPatch.esm.js +131 -0
- package/internal/Differ/ContextPatch.esm.js +158 -0
- package/internal/Differ/HashMapPatch.esm.js +133 -0
- package/internal/Differ/HashSetPatch.esm.js +107 -0
- package/internal/Differ/OrPatch.esm.js +196 -0
- package/internal/Differ.esm.js +130 -0
- package/internal/Effectable.esm.js +89 -0
- package/internal/Either.esm.js +95 -0
- package/internal/Encoding/Base64.esm.js +74 -0
- package/internal/Encoding/Base64Url.esm.js +24 -0
- package/internal/Encoding/Common.esm.js +21 -0
- package/internal/Encoding/Hex.esm.js +55 -0
- package/internal/HashMap/array.esm.js +51 -0
- package/internal/HashMap/bitwise.esm.js +34 -0
- package/internal/HashMap/config.esm.js +16 -0
- package/internal/HashMap/keySet.esm.js +8 -0
- package/internal/HashMap/node.esm.js +253 -0
- package/internal/HashMap.esm.js +366 -0
- package/internal/HashSet.esm.js +211 -0
- package/internal/Option.esm.js +75 -0
- package/internal/ReadonlyArray.esm.js +8 -0
- package/internal/RedBlackTree/iterator.esm.js +204 -0
- package/internal/RedBlackTree/node.esm.js +43 -0
- package/internal/RedBlackTree.esm.js +1042 -0
- package/internal/Stack.esm.js +9 -0
- package/internal/blockedRequests.esm.js +365 -0
- package/internal/cache.esm.js +514 -0
- package/internal/cause.esm.js +1067 -0
- package/internal/channel/channelExecutor.esm.js +692 -0
- package/internal/channel/channelState.esm.js +78 -0
- package/internal/channel/childExecutorDecision.esm.js +71 -0
- package/internal/channel/continuation.esm.js +58 -0
- package/internal/channel/mergeDecision.esm.js +69 -0
- package/internal/channel/mergeState.esm.js +82 -0
- package/internal/channel/mergeStrategy.esm.js +55 -0
- package/internal/channel/singleProducerAsyncInput.esm.js +191 -0
- package/internal/channel/subexecutor.esm.js +153 -0
- package/internal/channel/upstreamPullRequest.esm.js +62 -0
- package/internal/channel/upstreamPullStrategy.esm.js +62 -0
- package/internal/channel.esm.js +648 -0
- package/internal/clock.esm.js +82 -0
- package/internal/completedRequestMap.esm.js +7 -0
- package/internal/concurrency.esm.js +47 -0
- package/internal/config.esm.js +374 -0
- package/internal/configError.esm.js +276 -0
- package/internal/configProvider/pathPatch.esm.js +83 -0
- package/internal/configProvider.esm.js +365 -0
- package/internal/configSecret.esm.js +66 -0
- package/internal/console.esm.js +72 -0
- package/internal/core-effect.esm.js +875 -0
- package/internal/core-stream.esm.js +293 -0
- package/internal/core.esm.js +1745 -0
- package/internal/dataSource.esm.js +61 -0
- package/internal/defaultServices/console.esm.js +96 -0
- package/internal/defaultServices.esm.js +84 -0
- package/internal/deferred.esm.js +37 -0
- package/internal/effect/circular.esm.js +314 -0
- package/internal/executionStrategy.esm.js +61 -0
- package/internal/fiber.esm.js +257 -0
- package/internal/fiberId.esm.js +243 -0
- package/internal/fiberMessage.esm.js +54 -0
- package/internal/fiberRefs/patch.esm.js +127 -0
- package/internal/fiberRefs.esm.js +169 -0
- package/internal/fiberRuntime.esm.js +2003 -0
- package/internal/fiberScope.esm.js +58 -0
- package/internal/fiberStatus.esm.js +89 -0
- package/internal/groupBy.esm.js +208 -0
- package/internal/hub.esm.js +1102 -0
- package/internal/keyedPool.esm.js +161 -0
- package/internal/layer/circular.esm.js +84 -0
- package/internal/layer.esm.js +552 -0
- package/internal/logSpan.esm.js +15 -0
- package/internal/logger-circular.esm.js +21 -0
- package/internal/logger.esm.js +213 -0
- package/internal/metric/boundaries.esm.js +48 -0
- package/internal/metric/hook.esm.js +362 -0
- package/internal/metric/key.esm.js +68 -0
- package/internal/metric/keyType.esm.js +218 -0
- package/internal/metric/label.esm.js +40 -0
- package/internal/metric/pair.esm.js +38 -0
- package/internal/metric/polling.esm.js +74 -0
- package/internal/metric/registry.esm.js +111 -0
- package/internal/metric/state.esm.js +209 -0
- package/internal/metric.esm.js +204 -0
- package/internal/opCodes/cause.esm.js +31 -0
- package/internal/opCodes/channel.esm.js +71 -0
- package/internal/opCodes/channelChildExecutorDecision.esm.js +16 -0
- package/internal/opCodes/channelMergeDecision.esm.js +11 -0
- package/internal/opCodes/channelMergeState.esm.js +16 -0
- package/internal/opCodes/channelMergeStrategy.esm.js +11 -0
- package/internal/opCodes/channelState.esm.js +21 -0
- package/internal/opCodes/channelUpstreamPullRequest.esm.js +11 -0
- package/internal/opCodes/channelUpstreamPullStrategy.esm.js +11 -0
- package/internal/opCodes/config.esm.js +56 -0
- package/internal/opCodes/configError.esm.js +31 -0
- package/internal/opCodes/continuation.esm.js +11 -0
- package/internal/opCodes/deferred.esm.js +11 -0
- package/internal/opCodes/effect.esm.js +71 -0
- package/internal/opCodes/layer.esm.js +46 -0
- package/internal/opCodes/streamHaltStrategy.esm.js +21 -0
- package/internal/pool.esm.js +271 -0
- package/internal/query.esm.js +100 -0
- package/internal/queue.esm.js +505 -0
- package/internal/random.esm.js +58 -0
- package/internal/ref.esm.js +121 -0
- package/internal/reloadable.esm.js +62 -0
- package/internal/request.esm.js +81 -0
- package/internal/resource.esm.js +35 -0
- package/internal/ringBuffer.esm.js +56 -0
- package/internal/runtime.esm.js +268 -0
- package/internal/runtimeFlags.esm.js +137 -0
- package/internal/runtimeFlagsPatch.esm.js +57 -0
- package/internal/schedule/decision.esm.js +45 -0
- package/internal/schedule/interval.esm.js +85 -0
- package/internal/schedule/intervals.esm.js +135 -0
- package/internal/schedule.esm.js +844 -0
- package/internal/scopedCache.esm.js +406 -0
- package/internal/scopedRef.esm.js +49 -0
- package/internal/singleShotGen.esm.js +30 -0
- package/internal/sink.esm.js +918 -0
- package/internal/stm/core.esm.js +553 -0
- package/internal/stm/opCodes/stm.esm.js +56 -0
- package/internal/stm/opCodes/stmState.esm.js +16 -0
- package/internal/stm/opCodes/strategy.esm.js +16 -0
- package/internal/stm/opCodes/tExit.esm.js +26 -0
- package/internal/stm/opCodes/tryCommit.esm.js +11 -0
- package/internal/stm/stm/entry.esm.js +47 -0
- package/internal/stm/stm/journal.esm.js +96 -0
- package/internal/stm/stm/stmState.esm.js +104 -0
- package/internal/stm/stm/tExit.esm.js +113 -0
- package/internal/stm/stm/tryCommit.esm.js +25 -0
- package/internal/stm/stm/txnId.esm.js +15 -0
- package/internal/stm/stm/versioned.esm.js +8 -0
- package/internal/stm/stm.esm.js +584 -0
- package/internal/stm/tArray.esm.js +287 -0
- package/internal/stm/tDeferred.esm.js +49 -0
- package/internal/stm/tHub.esm.js +381 -0
- package/internal/stm/tMap.esm.js +492 -0
- package/internal/stm/tPriorityQueue.esm.js +156 -0
- package/internal/stm/tQueue.esm.js +317 -0
- package/internal/stm/tRandom.esm.js +89 -0
- package/internal/stm/tReentrantLock.esm.js +216 -0
- package/internal/stm/tRef.esm.js +117 -0
- package/internal/stm/tSemaphore.esm.js +73 -0
- package/internal/stm/tSet.esm.js +113 -0
- package/internal/stream/debounceState.esm.js +39 -0
- package/internal/stream/emit.esm.js +51 -0
- package/internal/stream/haltStrategy.esm.js +74 -0
- package/internal/stream/handoff.esm.js +79 -0
- package/internal/stream/handoffSignal.esm.js +40 -0
- package/internal/stream/pull.esm.js +10 -0
- package/internal/stream/sinkEndReason.esm.js +27 -0
- package/internal/stream/zipAllState.esm.js +65 -0
- package/internal/stream/zipChunksState.esm.js +41 -0
- package/internal/stream.esm.js +2984 -0
- package/internal/string-utils.esm.js +66 -0
- package/internal/subscriptionRef.esm.js +65 -0
- package/internal/supervisor/patch.esm.js +156 -0
- package/internal/supervisor.esm.js +204 -0
- package/internal/synchronizedRef.esm.js +53 -0
- package/internal/take.esm.js +130 -0
- package/internal/testing/suspendedWarningData.esm.js +66 -0
- package/internal/testing/warningData.esm.js +75 -0
- package/internal/timeout.esm.js +22 -0
- package/internal/tracer.esm.js +61 -0
- package/package.json +700 -554
- package/dist/Bigint-1c684209.esm.js +0 -370
- package/dist/Bigint-504df838.cjs.dev.js +0 -392
- package/dist/Bigint-d1a7e44e.cjs.prod.js +0 -392
- package/dist/Boolean-7513c999.cjs.prod.js +0 -264
- package/dist/Boolean-9427fc24.cjs.dev.js +0 -264
- package/dist/Boolean-f564d31a.esm.js +0 -248
- package/dist/Brand-c3918667.cjs.dev.js +0 -224
- package/dist/Brand-fa4e9f22.esm.js +0 -215
- package/dist/Brand-ff4af468.cjs.prod.js +0 -224
- package/dist/Cache-447337f2.esm.js +0 -120
- package/dist/Cache-4b4ea2b3.cjs.prod.js +0 -127
- package/dist/Cache-62ebdae3.cjs.dev.js +0 -127
- package/dist/Cause-8be0b9a6.esm.js +0 -730
- package/dist/Cause-b769f517.cjs.prod.js +0 -791
- package/dist/Cause-d77e20dc.cjs.dev.js +0 -791
- package/dist/Channel-2039c280.cjs.dev.js +0 -1217
- package/dist/Channel-806a0a5a.esm.js +0 -1109
- package/dist/Channel-dcff73a4.cjs.prod.js +0 -1217
- package/dist/ChannelChildExecutorDecision-2d3c20b1.esm.js +0 -125
- package/dist/ChannelChildExecutorDecision-adce4b58.cjs.dev.js +0 -136
- package/dist/ChannelChildExecutorDecision-fc90c987.cjs.prod.js +0 -136
- package/dist/ChannelMergeDecision-39e12893.cjs.prod.js +0 -78
- package/dist/ChannelMergeDecision-4488ba22.esm.js +0 -70
- package/dist/ChannelMergeDecision-f05da806.cjs.dev.js +0 -78
- package/dist/ChannelMergeState-65723a71.cjs.dev.js +0 -125
- package/dist/ChannelMergeState-937282d2.esm.js +0 -114
- package/dist/ChannelMergeState-ab626a77.cjs.prod.js +0 -125
- package/dist/ChannelMergeStrategy-c2f956a9.esm.js +0 -95
- package/dist/ChannelMergeStrategy-d5bdc89d.cjs.prod.js +0 -104
- package/dist/ChannelMergeStrategy-d956e3fa.cjs.dev.js +0 -104
- package/dist/ChannelSingleProducerAsyncInput-00708a29.esm.js +0 -52
- package/dist/ChannelSingleProducerAsyncInput-90f3b171.cjs.prod.js +0 -55
- package/dist/ChannelSingleProducerAsyncInput-ecc79242.cjs.dev.js +0 -55
- package/dist/ChannelUpstreamPullRequest-011526e6.esm.js +0 -95
- package/dist/ChannelUpstreamPullRequest-6a610523.cjs.dev.js +0 -104
- package/dist/ChannelUpstreamPullRequest-d7413c53.cjs.prod.js +0 -104
- package/dist/ChannelUpstreamPullStrategy-0af49b72.esm.js +0 -94
- package/dist/ChannelUpstreamPullStrategy-6e0a338e.cjs.prod.js +0 -103
- package/dist/ChannelUpstreamPullStrategy-90ec240c.cjs.dev.js +0 -103
- package/dist/Chunk-937f4423.cjs.dev.js +0 -1248
- package/dist/Chunk-98371336.esm.js +0 -1167
- package/dist/Chunk-f001938d.cjs.prod.js +0 -1248
- package/dist/Clock-27c1110d.cjs.prod.js +0 -97
- package/dist/Clock-589e9dc5.cjs.dev.js +0 -97
- package/dist/Clock-ab907687.esm.js +0 -88
- package/dist/Config-50e56bbd.cjs.prod.js +0 -393
- package/dist/Config-7e7f7335.cjs.dev.js +0 -393
- package/dist/Config-a3a06665.esm.js +0 -358
- package/dist/ConfigError-5801d561.esm.js +0 -206
- package/dist/ConfigError-684b6267.cjs.dev.js +0 -225
- package/dist/ConfigError-f5303a19.cjs.prod.js +0 -225
- package/dist/ConfigProvider-0aeb6513.esm.js +0 -220
- package/dist/ConfigProvider-b47b08f3.cjs.dev.js +0 -240
- package/dist/ConfigProvider-e278c5f7.cjs.prod.js +0 -240
- package/dist/ConfigProviderPathPatch-78826e8c.cjs.dev.js +0 -86
- package/dist/ConfigProviderPathPatch-97b52760.esm.js +0 -79
- package/dist/ConfigProviderPathPatch-bb5f5228.cjs.prod.js +0 -86
- package/dist/ConfigSecret-2db4c372.cjs.prod.js +0 -83
- package/dist/ConfigSecret-646df696.esm.js +0 -74
- package/dist/ConfigSecret-a10a12aa.cjs.dev.js +0 -83
- package/dist/Console-b92ceaf0.esm.js +0 -247
- package/dist/Console-d4590f3a.cjs.prod.js +0 -271
- package/dist/Console-f063615c.cjs.dev.js +0 -271
- package/dist/Context-119d62eb.cjs.prod.js +0 -327
- package/dist/Context-231e9c1b.cjs.prod.js +0 -222
- package/dist/Context-48179faa.esm.js +0 -312
- package/dist/Context-5099940c.cjs.dev.js +0 -222
- package/dist/Context-fcee7bba.esm.js +0 -208
- package/dist/Context-fdaa5c44.cjs.dev.js +0 -327
- package/dist/Data-3389525f.cjs.dev.js +0 -237
- package/dist/Data-815a1868.cjs.prod.js +0 -237
- package/dist/Data-bad1ffeb.esm.js +0 -224
- package/dist/DefaultServices-848d6929.cjs.dev.js +0 -34
- package/dist/DefaultServices-8c298120.esm.js +0 -30
- package/dist/DefaultServices-9ea98d30.cjs.prod.js +0 -34
- package/dist/Deferred-143efa7b.cjs.dev.js +0 -253
- package/dist/Deferred-554d3588.esm.js +0 -230
- package/dist/Deferred-77579e00.cjs.prod.js +0 -253
- package/dist/Differ-0069a8c0.cjs.dev.js +0 -992
- package/dist/Differ-3be1df41.esm.js +0 -975
- package/dist/Differ-cbfa45cb.cjs.prod.js +0 -992
- package/dist/Duration-205d0b80.cjs.prod.js +0 -500
- package/dist/Duration-5e9f2327.esm.js +0 -467
- package/dist/Duration-8b174e0b.cjs.dev.js +0 -500
- package/dist/Effect-6713972b.cjs.prod.js +0 -3740
- package/dist/Effect-d362f43a.cjs.dev.js +0 -3740
- package/dist/Effect-d5910dae.esm.js +0 -3417
- package/dist/Effectable-2c8e8441.cjs.prod.js +0 -99
- package/dist/Effectable-954172fc.cjs.prod.js +0 -181
- package/dist/Effectable-a76b6aa1.esm.js +0 -158
- package/dist/Effectable-bc017f96.cjs.dev.js +0 -99
- package/dist/Effectable-e85a1847.cjs.dev.js +0 -181
- package/dist/Effectable-ec9e4204.esm.js +0 -89
- package/dist/Either-09270bbc.esm.js +0 -473
- package/dist/Either-34ce9059.cjs.dev.js +0 -178
- package/dist/Either-41cb7522.cjs.prod.js +0 -178
- package/dist/Either-ae722a9e.cjs.dev.js +0 -502
- package/dist/Either-be9c40b9.esm.js +0 -163
- package/dist/Either-d995ebb4.cjs.prod.js +0 -502
- package/dist/Encoding-0d990bbf.esm.js +0 -295
- package/dist/Encoding-39f7d9a8.cjs.dev.js +0 -309
- package/dist/Encoding-82d009b9.cjs.prod.js +0 -309
- package/dist/Equal-7d4ae7e7.esm.js +0 -65
- package/dist/Equal-8654b1af.cjs.dev.js +0 -71
- package/dist/Equal-ed1e8c3c.cjs.prod.js +0 -71
- package/dist/Equivalence-87295c78.cjs.prod.js +0 -238
- package/dist/Equivalence-a4b5f56d.cjs.dev.js +0 -238
- package/dist/Equivalence-e5c9cba4.esm.js +0 -218
- package/dist/Error-7e84d828.esm.js +0 -53
- package/dist/Error-be89adc9.cjs.prod.js +0 -57
- package/dist/Error-e1ceeea7.cjs.dev.js +0 -57
- package/dist/ExecutionStrategy-080f0b2b.cjs.prod.js +0 -180
- package/dist/ExecutionStrategy-c6f7c490.esm.js +0 -168
- package/dist/ExecutionStrategy-cd9204b4.cjs.dev.js +0 -180
- package/dist/Exit-7a385294.cjs.dev.js +0 -408
- package/dist/Exit-e31718e3.esm.js +0 -371
- package/dist/Exit-eb04f98e.cjs.prod.js +0 -408
- package/dist/Fiber-1a996e3f.cjs.dev.js +0 -521
- package/dist/Fiber-38517971.esm.js +0 -473
- package/dist/Fiber-a7306b77.cjs.prod.js +0 -521
- package/dist/FiberId-3b23bc04.cjs.dev.js +0 -443
- package/dist/FiberId-556ab9ef.esm.js +0 -422
- package/dist/FiberId-95c92b7e.cjs.prod.js +0 -443
- package/dist/FiberRef-6f63843b.cjs.prod.js +0 -385
- package/dist/FiberRef-912b6248.cjs.dev.js +0 -385
- package/dist/FiberRef-b81d5a7e.esm.js +0 -338
- package/dist/FiberRefs-1a6a1b5f.cjs.prod.js +0 -135
- package/dist/FiberRefs-44fda74a.cjs.dev.js +0 -135
- package/dist/FiberRefs-a6ab4b8d.esm.js +0 -122
- package/dist/FiberRefsPatch-549967e3.cjs.prod.js +0 -90
- package/dist/FiberRefsPatch-56f10acc.cjs.dev.js +0 -90
- package/dist/FiberRefsPatch-f84453c3.esm.js +0 -84
- package/dist/FiberStatus-90291b8c.esm.js +0 -187
- package/dist/FiberStatus-db497d70.cjs.dev.js +0 -197
- package/dist/FiberStatus-ff18b445.cjs.prod.js +0 -197
- package/dist/Function-52fb7d21.esm.js +0 -516
- package/dist/Function-8336aeeb.cjs.prod.js +0 -538
- package/dist/Function-fd10bde3.cjs.dev.js +0 -538
- package/dist/GlobalValue-00457222.cjs.dev.js +0 -28
- package/dist/GlobalValue-c5f1e8e5.esm.js +0 -25
- package/dist/GlobalValue-f65cc41d.cjs.prod.js +0 -28
- package/dist/GroupBy-cabfa667.cjs.dev.js +0 -79
- package/dist/GroupBy-d0ad2148.cjs.prod.js +0 -79
- package/dist/GroupBy-eef333fa.esm.js +0 -72
- package/dist/HKT-1990744d.esm.js +0 -5
- package/dist/Hash-039222d1.esm.js +0 -179
- package/dist/Hash-2171bcec.cjs.prod.js +0 -192
- package/dist/Hash-9d5502e5.cjs.dev.js +0 -192
- package/dist/HashMap-2604a8b0.cjs.prod.js +0 -361
- package/dist/HashMap-e644e23b.esm.js +0 -327
- package/dist/HashMap-ee35ace5.cjs.dev.js +0 -361
- package/dist/HashSet-206ea53b.cjs.dev.js +0 -965
- package/dist/HashSet-286fb998.cjs.prod.js +0 -965
- package/dist/HashSet-43b520e9.cjs.dev.js +0 -283
- package/dist/HashSet-99f1529e.cjs.prod.js +0 -283
- package/dist/HashSet-d051e0ea.esm.js +0 -907
- package/dist/HashSet-dff2542b.esm.js +0 -256
- package/dist/Hub-4223bb07.cjs.prod.js +0 -1280
- package/dist/Hub-9f3d5c5d.esm.js +0 -1264
- package/dist/Hub-dd9d70e7.cjs.dev.js +0 -1280
- package/dist/Inspectable-46a7668e.cjs.prod.js +0 -50
- package/dist/Inspectable-654412c2.cjs.dev.js +0 -50
- package/dist/Inspectable-bda84223.esm.js +0 -45
- package/dist/KeyedPool-0b5851a2.cjs.prod.js +0 -282
- package/dist/KeyedPool-50b8f75b.esm.js +0 -273
- package/dist/KeyedPool-8b979aac.cjs.dev.js +0 -282
- package/dist/Layer-11122c64.cjs.dev.js +0 -687
- package/dist/Layer-79fa5f4a.cjs.prod.js +0 -687
- package/dist/Layer-f7be72db.esm.js +0 -623
- package/dist/List-48f2b78f.cjs.prod.js +0 -912
- package/dist/List-95e1e081.cjs.dev.js +0 -912
- package/dist/List-c066a506.esm.js +0 -865
- package/dist/LogLevel-2e6b00c7.esm.js +0 -222
- package/dist/LogLevel-a609dd63.cjs.prod.js +0 -240
- package/dist/LogLevel-c14e29fb.cjs.dev.js +0 -240
- package/dist/LogSpan-c216a78b.cjs.prod.js +0 -46
- package/dist/LogSpan-cd4b8f34.cjs.dev.js +0 -46
- package/dist/LogSpan-e5cf11a5.esm.js +0 -42
- package/dist/Logger-029fccab.cjs.prod.js +0 -275
- package/dist/Logger-28d5e7ff.cjs.dev.js +0 -275
- package/dist/Logger-52ffeafa.esm.js +0 -246
- package/dist/Metric-2b4867b2.cjs.dev.js +0 -488
- package/dist/Metric-cd4dfaba.cjs.prod.js +0 -488
- package/dist/Metric-f2c8888b.esm.js +0 -442
- package/dist/MetricBoundaries-8ef331f0.cjs.dev.js +0 -68
- package/dist/MetricBoundaries-9707829f.esm.js +0 -61
- package/dist/MetricBoundaries-fc377a5e.cjs.prod.js +0 -68
- package/dist/MetricHook-74ebef65.esm.js +0 -80
- package/dist/MetricHook-9d1ff9f5.cjs.prod.js +0 -90
- package/dist/MetricHook-ebd34eea.cjs.dev.js +0 -90
- package/dist/MetricKey-7536999c.cjs.dev.js +0 -130
- package/dist/MetricKey-d96ef128.cjs.prod.js +0 -130
- package/dist/MetricKey-fb261d1b.esm.js +0 -118
- package/dist/MetricKeyType-637f6694.cjs.prod.js +0 -187
- package/dist/MetricKeyType-6a10f955.esm.js +0 -168
- package/dist/MetricKeyType-ed70a508.cjs.dev.js +0 -187
- package/dist/MetricLabel-30df73d1.esm.js +0 -48
- package/dist/MetricLabel-b6a3c628.cjs.prod.js +0 -53
- package/dist/MetricLabel-e6d1cb96.cjs.dev.js +0 -53
- package/dist/MetricPair-5f5f6f1b.esm.js +0 -45
- package/dist/MetricPair-a1551790.cjs.prod.js +0 -50
- package/dist/MetricPair-f1f0edbd.cjs.dev.js +0 -50
- package/dist/MetricPolling-258af71e.esm.js +0 -167
- package/dist/MetricPolling-b2accbbd.cjs.dev.js +0 -177
- package/dist/MetricPolling-c6caba9d.cjs.prod.js +0 -177
- package/dist/MetricRegistry-2ae45fdf.cjs.dev.js +0 -38
- package/dist/MetricRegistry-44d3af51.esm.js +0 -34
- package/dist/MetricRegistry-d61eb47d.cjs.prod.js +0 -38
- package/dist/MetricState-a3499d98.cjs.prod.js +0 -191
- package/dist/MetricState-cd7a1775.cjs.dev.js +0 -191
- package/dist/MetricState-d4fcb7d0.esm.js +0 -172
- package/dist/MutableHashMap-b3ab7261.esm.js +0 -142
- package/dist/MutableHashMap-d6cb38d9.cjs.prod.js +0 -154
- package/dist/MutableHashMap-f08d01f5.cjs.dev.js +0 -154
- package/dist/MutableHashSet-9e2ea672.cjs.dev.js +0 -110
- package/dist/MutableHashSet-ec9f7a0b.esm.js +0 -101
- package/dist/MutableHashSet-fa860611.cjs.prod.js +0 -110
- package/dist/MutableList-4ef847b7.cjs.prod.js +0 -296
- package/dist/MutableList-85cf4e37.cjs.dev.js +0 -296
- package/dist/MutableList-8c671944.esm.js +0 -281
- package/dist/MutableQueue-3dfd5fea.cjs.dev.js +0 -215
- package/dist/MutableQueue-416dfcd9.cjs.prod.js +0 -215
- package/dist/MutableQueue-54a4b584.esm.js +0 -202
- package/dist/MutableRef-82c6fe46.cjs.prod.js +0 -194
- package/dist/MutableRef-cb4d2fc0.esm.js +0 -176
- package/dist/MutableRef-ef31c15d.cjs.dev.js +0 -194
- package/dist/NonEmptyIterable-26ed16e4.cjs.prod.js +0 -36
- package/dist/NonEmptyIterable-7ef320e0.esm.js +0 -33
- package/dist/NonEmptyIterable-b064c1af.cjs.dev.js +0 -36
- package/dist/Number-d021c8f9.cjs.prod.js +0 -417
- package/dist/Number-dc454336.esm.js +0 -394
- package/dist/Number-dddf713e.cjs.dev.js +0 -417
- package/dist/Option-1d073850.esm.js +0 -1135
- package/dist/Option-837ae0da.cjs.dev.js +0 -1198
- package/dist/Option-b07f2b1d.cjs.prod.js +0 -1198
- package/dist/Order-2f11aa24.esm.js +0 -293
- package/dist/Order-2f785421.cjs.prod.js +0 -321
- package/dist/Order-cbf22e18.cjs.dev.js +0 -321
- package/dist/Ordering-9892085c.esm.js +0 -97
- package/dist/Ordering-e20427cc.cjs.dev.js +0 -104
- package/dist/Ordering-f3e378ef.cjs.prod.js +0 -104
- package/dist/Pipeable-856ddd7c.cjs.prod.js +0 -52
- package/dist/Pipeable-ef202667.cjs.dev.js +0 -52
- package/dist/Pipeable-fe51dc02.esm.js +0 -49
- package/dist/Pool-68590a64.cjs.dev.js +0 -122
- package/dist/Pool-718f79ff.cjs.prod.js +0 -122
- package/dist/Pool-cdfcfabe.esm.js +0 -114
- package/dist/Predicate-52271838.esm.js +0 -677
- package/dist/Predicate-54d8c8de.cjs.dev.js +0 -718
- package/dist/Predicate-a3fd4088.cjs.prod.js +0 -718
- package/dist/Queue-48d0b9d4.cjs.dev.js +0 -394
- package/dist/Queue-9f8579c0.cjs.prod.js +0 -394
- package/dist/Queue-bbebbeda.esm.js +0 -362
- package/dist/Random-0bdc1bcb.cjs.prod.js +0 -104
- package/dist/Random-14987953.esm.js +0 -94
- package/dist/Random-f495bcbc.cjs.dev.js +0 -104
- package/dist/ReadonlyArray-199ff80e.esm.js +0 -1584
- package/dist/ReadonlyArray-3b1a15d8.cjs.dev.js +0 -10
- package/dist/ReadonlyArray-6fbc78a1.cjs.prod.js +0 -1721
- package/dist/ReadonlyArray-84c71385.esm.js +0 -8
- package/dist/ReadonlyArray-885e80a2.cjs.dev.js +0 -1721
- package/dist/ReadonlyArray-8adb9a46.cjs.prod.js +0 -10
- package/dist/ReadonlyRecord-4969b34f.cjs.prod.js +0 -568
- package/dist/ReadonlyRecord-c1f5d048.esm.js +0 -544
- package/dist/ReadonlyRecord-c6dc7deb.cjs.dev.js +0 -568
- package/dist/RedBlackTree-22839235.esm.js +0 -1632
- package/dist/RedBlackTree-59192950.cjs.prod.js +0 -1669
- package/dist/RedBlackTree-98a93ec6.cjs.dev.js +0 -1669
- package/dist/Ref-88c1d56d.cjs.prod.js +0 -282
- package/dist/Ref-8d85fc7a.cjs.dev.js +0 -282
- package/dist/Ref-9a9de951.esm.js +0 -248
- package/dist/Reloadable-10cfae17.esm.js +0 -159
- package/dist/Reloadable-3ca716d9.cjs.prod.js +0 -169
- package/dist/Reloadable-65bf6783.cjs.dev.js +0 -169
- package/dist/Request-5b794c27.cjs.dev.js +0 -190
- package/dist/Request-6d646956.cjs.prod.js +0 -190
- package/dist/Request-9f0b571a.esm.js +0 -175
- package/dist/RequestBlock-15e7d048.cjs.prod.js +0 -124
- package/dist/RequestBlock-6105623d.esm.js +0 -114
- package/dist/RequestBlock-ec5299d4.cjs.dev.js +0 -124
- package/dist/RequestResolver-10227a7b.esm.js +0 -213
- package/dist/RequestResolver-a3fe9b72.cjs.prod.js +0 -233
- package/dist/RequestResolver-bc7e6050.cjs.dev.js +0 -233
- package/dist/Resource-966460b5.cjs.dev.js +0 -118
- package/dist/Resource-9f1084b9.cjs.prod.js +0 -118
- package/dist/Resource-afd128d6.esm.js +0 -111
- package/dist/Runtime-15bf8fcd.cjs.prod.js +0 -191
- package/dist/Runtime-1a63e954.cjs.dev.js +0 -191
- package/dist/Runtime-4f6fc384.esm.js +0 -175
- package/dist/RuntimeFlags-4d3b4ba7.esm.js +0 -344
- package/dist/RuntimeFlags-a43dcce7.cjs.dev.js +0 -381
- package/dist/RuntimeFlags-ef10d73a.cjs.prod.js +0 -381
- package/dist/RuntimeFlagsPatch-0c131e8e.cjs.dev.js +0 -411
- package/dist/RuntimeFlagsPatch-a1da6096.esm.js +0 -365
- package/dist/RuntimeFlagsPatch-bfdf133d.cjs.prod.js +0 -411
- package/dist/STM-2bdad2bd.cjs.dev.js +0 -1447
- package/dist/STM-55e91604.esm.js +0 -1321
- package/dist/STM-e6749b84.cjs.prod.js +0 -1447
- package/dist/Schedule-35a9436e.cjs.prod.js +0 -1159
- package/dist/Schedule-d9b0f037.cjs.dev.js +0 -1159
- package/dist/Schedule-da001b13.esm.js +0 -1059
- package/dist/ScheduleDecision-2ab823c2.cjs.dev.js +0 -106
- package/dist/ScheduleDecision-369cf2a1.cjs.prod.js +0 -106
- package/dist/ScheduleDecision-e794f66d.esm.js +0 -99
- package/dist/ScheduleInterval-2db9be83.cjs.dev.js +0 -244
- package/dist/ScheduleInterval-3e9b8eca.cjs.prod.js +0 -244
- package/dist/ScheduleInterval-94e80ec4.esm.js +0 -229
- package/dist/ScheduleIntervals-ab412802.cjs.dev.js +0 -265
- package/dist/ScheduleIntervals-e6ed15fa.cjs.prod.js +0 -265
- package/dist/ScheduleIntervals-ef5cd7c5.esm.js +0 -252
- package/dist/Scheduler-44f252da.cjs.prod.js +0 -358
- package/dist/Scheduler-6122a3ee.cjs.dev.js +0 -358
- package/dist/Scheduler-d2f7e5c7.esm.js +0 -343
- package/dist/Scope-0ffde3bb.esm.js +0 -131
- package/dist/Scope-326194e2.cjs.prod.js +0 -143
- package/dist/Scope-3cf29072.cjs.dev.js +0 -143
- package/dist/ScopedCache-01a07a6d.cjs.prod.js +0 -467
- package/dist/ScopedCache-77c605e8.cjs.dev.js +0 -467
- package/dist/ScopedCache-9c558fd1.esm.js +0 -462
- package/dist/ScopedRef-2f0e2b33.cjs.dev.js +0 -87
- package/dist/ScopedRef-5c29a8a2.cjs.prod.js +0 -87
- package/dist/ScopedRef-dd8a823e.esm.js +0 -80
- package/dist/Sink-923b4ad8.esm.js +0 -1107
- package/dist/Sink-c4ca577a.cjs.prod.js +0 -1215
- package/dist/Sink-fa1f105b.cjs.dev.js +0 -1215
- package/dist/SortedMap-44f47d83.esm.js +0 -190
- package/dist/SortedMap-abf39a75.cjs.prod.js +0 -210
- package/dist/SortedMap-b04da739.cjs.dev.js +0 -210
- package/dist/SortedSet-3339ea7f.esm.js +0 -288
- package/dist/SortedSet-4efa4f05.cjs.dev.js +0 -311
- package/dist/SortedSet-b588ac70.cjs.prod.js +0 -311
- package/dist/Stack-765c2298.esm.js +0 -9
- package/dist/Stream-1d51d0be.esm.js +0 -3175
- package/dist/Stream-55dd689b.cjs.prod.js +0 -3469
- package/dist/Stream-b1eaedfc.cjs.dev.js +0 -3469
- package/dist/StreamEmit-bd696ab0.esm.js +0 -5
- package/dist/StreamHaltStrategy-292ed375.cjs.dev.js +0 -214
- package/dist/StreamHaltStrategy-506d4abb.cjs.prod.js +0 -214
- package/dist/StreamHaltStrategy-9864a080.esm.js +0 -201
- package/dist/String-9702a941.cjs.dev.js +0 -694
- package/dist/String-ba45d520.esm.js +0 -648
- package/dist/String-fa7c1c88.cjs.prod.js +0 -694
- package/dist/Struct-3d8b2a81.cjs.prod.js +0 -141
- package/dist/Struct-62f329c0.cjs.dev.js +0 -141
- package/dist/Struct-8bc142d1.esm.js +0 -134
- package/dist/SubscriptionRef-1eb76544.cjs.prod.js +0 -269
- package/dist/SubscriptionRef-33b302b6.esm.js +0 -245
- package/dist/SubscriptionRef-faf570c5.cjs.dev.js +0 -269
- package/dist/Supervisor-34de9985.cjs.dev.js +0 -170
- package/dist/Supervisor-3706300f.cjs.prod.js +0 -170
- package/dist/Supervisor-5b9943cf.esm.js +0 -160
- package/dist/Symbol-9ad0bde8.esm.js +0 -36
- package/dist/Symbol-e3ea5627.cjs.dev.js +0 -40
- package/dist/Symbol-e5af99ce.cjs.prod.js +0 -40
- package/dist/SynchronizedRef-01f585dc.cjs.prod.js +0 -212
- package/dist/SynchronizedRef-c389137f.esm.js +0 -187
- package/dist/SynchronizedRef-cda883b7.cjs.dev.js +0 -212
- package/dist/TArray-1200bf6a.esm.js +0 -412
- package/dist/TArray-97bc3f87.cjs.prod.js +0 -455
- package/dist/TArray-9bd73c38.cjs.dev.js +0 -455
- package/dist/TDeferred-875fd41c.esm.js +0 -120
- package/dist/TDeferred-bf21b756.cjs.prod.js +0 -129
- package/dist/TDeferred-f97247d3.cjs.dev.js +0 -129
- package/dist/THub-917198c0.esm.js +0 -553
- package/dist/THub-c4a3e52c.cjs.dev.js +0 -570
- package/dist/THub-d9d3b223.cjs.prod.js +0 -570
- package/dist/TMap-459696e5.cjs.dev.js +0 -463
- package/dist/TMap-786b8508.esm.js +0 -419
- package/dist/TMap-a6aab3c3.cjs.prod.js +0 -463
- package/dist/TPriorityQueue-31c32afb.esm.js +0 -360
- package/dist/TPriorityQueue-918056c3.cjs.prod.js +0 -381
- package/dist/TPriorityQueue-e8429066.cjs.dev.js +0 -381
- package/dist/TQueue-adee58b8.esm.js +0 -324
- package/dist/TQueue-b9593214.cjs.prod.js +0 -353
- package/dist/TQueue-d1c8153e.cjs.dev.js +0 -353
- package/dist/TRandom-65721a5b.cjs.prod.js +0 -203
- package/dist/TRandom-677ba64f.esm.js +0 -192
- package/dist/TRandom-79057bd9.cjs.dev.js +0 -203
- package/dist/TReentrantLock-0dbd6074.cjs.prod.js +0 -456
- package/dist/TReentrantLock-164c0898.cjs.dev.js +0 -456
- package/dist/TReentrantLock-65156c11.esm.js +0 -435
- package/dist/TRef-4a45f5af.cjs.dev.js +0 -152
- package/dist/TRef-edd5ff88.esm.js +0 -135
- package/dist/TRef-ff8497e4.cjs.prod.js +0 -152
- package/dist/TSemaphore-1f5dc074.cjs.dev.js +0 -197
- package/dist/TSemaphore-bccebfec.esm.js +0 -183
- package/dist/TSemaphore-d1096593.cjs.prod.js +0 -197
- package/dist/TSet-0f61d448.cjs.prod.js +0 -444
- package/dist/TSet-48903882.cjs.dev.js +0 -444
- package/dist/TSet-bd3a1de2.esm.js +0 -412
- package/dist/Take-1e6b1ba3.esm.js +0 -214
- package/dist/Take-7797160f.cjs.dev.js +0 -236
- package/dist/Take-d245cc08.cjs.prod.js +0 -236
- package/dist/TestAnnotation-5b23b64a.cjs.prod.js +0 -135
- package/dist/TestAnnotation-c2b6bb64.esm.js +0 -124
- package/dist/TestAnnotation-ca7ea5d9.cjs.dev.js +0 -135
- package/dist/TestAnnotationMap-5ef91d33.cjs.prod.js +0 -125
- package/dist/TestAnnotationMap-83b0e761.cjs.dev.js +0 -125
- package/dist/TestAnnotationMap-d180214b.esm.js +0 -114
- package/dist/TestAnnotations-758011e7.cjs.prod.js +0 -97
- package/dist/TestAnnotations-89733ab7.cjs.dev.js +0 -97
- package/dist/TestAnnotations-cf445345.esm.js +0 -91
- package/dist/TestClock-0a012f75.esm.js +0 -565
- package/dist/TestClock-0abac759.cjs.prod.js +0 -581
- package/dist/TestClock-3bdb0c0b.cjs.dev.js +0 -581
- package/dist/TestConfig-3f48c7f2.cjs.prod.js +0 -37
- package/dist/TestConfig-e52495c3.esm.js +0 -33
- package/dist/TestConfig-ff283076.cjs.dev.js +0 -37
- package/dist/TestContext-64f40523.esm.js +0 -36
- package/dist/TestContext-7a6420d3.cjs.prod.js +0 -41
- package/dist/TestContext-b44d97ae.cjs.dev.js +0 -41
- package/dist/TestLive-64c62bfe.cjs.dev.js +0 -60
- package/dist/TestLive-906c173d.cjs.prod.js +0 -60
- package/dist/TestLive-bfab4add.esm.js +0 -55
- package/dist/TestServices-844e305d.esm.js +0 -306
- package/dist/TestServices-944b625c.cjs.prod.js +0 -341
- package/dist/TestServices-f8c51bbd.cjs.dev.js +0 -341
- package/dist/TestSized-0fa739ff.cjs.prod.js +0 -64
- package/dist/TestSized-3a0fa658.esm.js +0 -58
- package/dist/TestSized-955a228e.cjs.dev.js +0 -64
- package/dist/Tracer-1610aba4.cjs.dev.js +0 -81
- package/dist/Tracer-700da80a.cjs.prod.js +0 -81
- package/dist/Tracer-b07052e2.esm.js +0 -75
- package/dist/Tuple-1fa12d6e.esm.js +0 -187
- package/dist/Tuple-73682170.cjs.prod.js +0 -199
- package/dist/Tuple-9822259f.cjs.dev.js +0 -199
- package/dist/Types-be3804ad.esm.js +0 -5
- package/dist/Unify-150ebcee.cjs.dev.js +0 -48
- package/dist/Unify-77f78d08.cjs.prod.js +0 -48
- package/dist/Unify-9d27a1f3.esm.js +0 -45
- package/dist/Utils-32587b0c.cjs.dev.js +0 -370
- package/dist/Utils-6484334f.cjs.prod.js +0 -370
- package/dist/Utils-657e8bfa.esm.js +0 -362
- package/dist/boundaries-6bacf30a.cjs.prod.js +0 -54
- package/dist/boundaries-8475a9b4.esm.js +0 -48
- package/dist/boundaries-c6f4c3da.cjs.dev.js +0 -54
- package/dist/cache-2fa366f0.esm.js +0 -514
- package/dist/cache-7b578624.cjs.prod.js +0 -523
- package/dist/cache-8db60799.cjs.dev.js +0 -523
- package/dist/childExecutorDecision-49f0f19c.esm.js +0 -85
- package/dist/childExecutorDecision-744cd5fb.cjs.prod.js +0 -98
- package/dist/childExecutorDecision-c1c3b8b6.cjs.dev.js +0 -98
- package/dist/circular-1dfea59d.cjs.prod.js +0 -107
- package/dist/circular-3ebc9b78.esm.js +0 -82
- package/dist/circular-604e98e5.cjs.prod.js +0 -341
- package/dist/circular-8088cc19.cjs.dev.js +0 -341
- package/dist/circular-cff58c30.esm.js +0 -311
- package/dist/circular-e5da795a.cjs.dev.js +0 -107
- package/dist/config-05de256b.cjs.dev.js +0 -474
- package/dist/config-3003c43a.cjs.prod.js +0 -474
- package/dist/config-64a67e36.esm.js +0 -428
- package/dist/configError-84c0742e.esm.js +0 -305
- package/dist/configError-a7c4fcc2.cjs.dev.js +0 -323
- package/dist/configError-b3dd6ec2.cjs.prod.js +0 -323
- package/dist/configProvider-35a1a3c7.cjs.prod.js +0 -447
- package/dist/configProvider-56d1b842.cjs.dev.js +0 -447
- package/dist/configProvider-cd15d971.esm.js +0 -428
- package/dist/configSecret-18ba6f6e.cjs.dev.js +0 -74
- package/dist/configSecret-3dd7ab72.cjs.prod.js +0 -74
- package/dist/configSecret-793e52b4.esm.js +0 -66
- package/dist/core-01c0ed9d.cjs.prod.js +0 -1072
- package/dist/core-218f7617.cjs.prod.js +0 -3502
- package/dist/core-5346c1e5.cjs.dev.js +0 -1072
- package/dist/core-9276b625.esm.js +0 -1032
- package/dist/core-9f5f0dc2.esm.js +0 -3225
- package/dist/core-bedc63fe.cjs.dev.js +0 -3502
- package/dist/core-effect-a839563d.cjs.dev.js +0 -1030
- package/dist/core-effect-e762d50b.esm.js +0 -902
- package/dist/core-effect-fea8dde9.cjs.prod.js +0 -1030
- package/dist/dataSource-43c62f8e.esm.js +0 -60
- package/dist/dataSource-8ab8a0ec.cjs.dev.js +0 -74
- package/dist/dataSource-cc1edaa1.cjs.prod.js +0 -74
- package/dist/defaultServices-1d4f144a.cjs.prod.js +0 -388
- package/dist/defaultServices-1f1298e8.cjs.dev.js +0 -388
- package/dist/defaultServices-86214de4.esm.js +0 -359
- package/dist/fiber-1511340a.esm.js +0 -363
- package/dist/fiber-18f7cf87.cjs.dev.js +0 -411
- package/dist/fiber-957d5291.cjs.prod.js +0 -411
- package/dist/fiberRefs-76ecbcfd.cjs.dev.js +0 -181
- package/dist/fiberRefs-b32de18b.esm.js +0 -169
- package/dist/fiberRefs-f0429b31.cjs.prod.js +0 -181
- package/dist/fiberRuntime-233db874.cjs.dev.js +0 -3012
- package/dist/fiberRuntime-5e42f85c.cjs.prod.js +0 -3012
- package/dist/fiberRuntime-98f09d31.esm.js +0 -2857
- package/dist/groupBy-36e6ca3f.cjs.prod.js +0 -216
- package/dist/groupBy-3a32c4b6.cjs.dev.js +0 -216
- package/dist/groupBy-8d753c19.esm.js +0 -206
- package/dist/hook-8fc9006f.esm.js +0 -362
- package/dist/hook-e169b712.cjs.prod.js +0 -371
- package/dist/hook-fe9f948d.cjs.dev.js +0 -371
- package/dist/key-215ea6fd.esm.js +0 -68
- package/dist/key-4824d1ad.cjs.prod.js +0 -79
- package/dist/key-d8dc829b.cjs.dev.js +0 -79
- package/dist/keyType-c980adcc.cjs.dev.js +0 -236
- package/dist/keyType-d85714ed.cjs.prod.js +0 -236
- package/dist/keyType-fefd9ef8.esm.js +0 -218
- package/dist/label-14b7d517.cjs.dev.js +0 -44
- package/dist/label-5cb21441.esm.js +0 -40
- package/dist/label-e78b2f8f.cjs.prod.js +0 -44
- package/dist/layer-3da5a933.cjs.prod.js +0 -658
- package/dist/layer-e1d1db03.cjs.dev.js +0 -658
- package/dist/layer-f8ec8454.esm.js +0 -596
- package/dist/mergeDecision-32146c34.esm.js +0 -78
- package/dist/mergeDecision-75feaab3.cjs.dev.js +0 -86
- package/dist/mergeDecision-a1822db2.cjs.prod.js +0 -86
- package/dist/mergeState-21728f0b.esm.js +0 -96
- package/dist/mergeState-2c24c562.cjs.prod.js +0 -109
- package/dist/mergeState-e9aa09b9.cjs.dev.js +0 -109
- package/dist/mergeStrategy-84dd9011.esm.js +0 -64
- package/dist/mergeStrategy-8fe47c7e.cjs.dev.js +0 -72
- package/dist/mergeStrategy-909bebb0.cjs.prod.js +0 -72
- package/dist/pair-67530b23.cjs.dev.js +0 -42
- package/dist/pair-cb46f77c.esm.js +0 -38
- package/dist/pair-fb591d12.cjs.prod.js +0 -42
- package/dist/patch-99e8591b.esm.js +0 -127
- package/dist/patch-cdcb5e42.cjs.dev.js +0 -132
- package/dist/patch-f440dab6.cjs.prod.js +0 -132
- package/dist/pathPatch-5ac830c8.esm.js +0 -83
- package/dist/pathPatch-75afe967.cjs.dev.js +0 -90
- package/dist/pathPatch-775a0838.cjs.prod.js +0 -90
- package/dist/pool-0da00d67.cjs.prod.js +0 -278
- package/dist/pool-54820a71.esm.js +0 -271
- package/dist/pool-bfa5c974.cjs.dev.js +0 -278
- package/dist/query-1685a476.esm.js +0 -97
- package/dist/query-3ab8cd4e.cjs.prod.js +0 -104
- package/dist/query-68bb7c45.cjs.dev.js +0 -104
- package/dist/queue-499cacee.cjs.prod.js +0 -538
- package/dist/queue-b79c472d.esm.js +0 -505
- package/dist/queue-bf262207.cjs.dev.js +0 -538
- package/dist/registry-38f0ed9d.esm.js +0 -111
- package/dist/registry-6f465b2f.cjs.prod.js +0 -114
- package/dist/registry-dfe7ed01.cjs.dev.js +0 -114
- package/dist/runtime-5b7472d5.cjs.dev.js +0 -288
- package/dist/runtime-68e90981.cjs.prod.js +0 -288
- package/dist/runtime-f91ca239.esm.js +0 -266
- package/dist/schedule-0d31f4cc.esm.js +0 -843
- package/dist/schedule-616cf1b8.cjs.prod.js +0 -956
- package/dist/schedule-d3f9b258.cjs.dev.js +0 -956
- package/dist/scopedRef-5e59cf54.cjs.prod.js +0 -55
- package/dist/scopedRef-730d8d35.cjs.dev.js +0 -55
- package/dist/scopedRef-e54a3d93.esm.js +0 -49
- package/dist/singleProducerAsyncInput-6508b7f1.cjs.dev.js +0 -193
- package/dist/singleProducerAsyncInput-c67ef1c6.esm.js +0 -191
- package/dist/singleProducerAsyncInput-d3225b4e.cjs.prod.js +0 -193
- package/dist/sink-05d54662.cjs.prod.js +0 -3094
- package/dist/sink-3105a90f.cjs.dev.js +0 -3094
- package/dist/sink-3f26fc31.esm.js +0 -2877
- package/dist/state-38610229.esm.js +0 -209
- package/dist/state-6d974829.cjs.dev.js +0 -227
- package/dist/state-abef4d59.cjs.prod.js +0 -227
- package/dist/stm-43c3b262.cjs.dev.js +0 -678
- package/dist/stm-d01a804c.esm.js +0 -582
- package/dist/stm-e1200304.cjs.prod.js +0 -678
- package/dist/stream-3ebec4f3.cjs.prod.js +0 -3649
- package/dist/stream-9270c6b1.esm.js +0 -3355
- package/dist/stream-b819c5b3.cjs.dev.js +0 -3649
- package/dist/synchronizedRef-5bbb64b2.cjs.prod.js +0 -62
- package/dist/synchronizedRef-e9682c8e.cjs.dev.js +0 -62
- package/dist/synchronizedRef-f7077a5f.esm.js +0 -53
- package/dist/tArray-0d2e8fae.cjs.dev.js +0 -330
- package/dist/tArray-442d22a4.cjs.prod.js +0 -330
- package/dist/tArray-fa2759e8.esm.js +0 -287
- package/dist/tMap-2a001015.cjs.prod.js +0 -535
- package/dist/tMap-2a98e9a7.esm.js +0 -492
- package/dist/tMap-2fd8c9e6.cjs.dev.js +0 -535
- package/dist/tQueue-13f8f402.esm.js +0 -331
- package/dist/tQueue-84a0d0eb.cjs.dev.js +0 -367
- package/dist/tQueue-e2e96d1f.cjs.prod.js +0 -367
- package/dist/tRef-4772a528.cjs.prod.js +0 -133
- package/dist/tRef-b5d0cc28.esm.js +0 -115
- package/dist/tRef-bbbdd134.cjs.dev.js +0 -133
- package/dist/take-68ed448f.cjs.dev.js +0 -152
- package/dist/take-7c168e8e.esm.js +0 -130
- package/dist/take-d293f721.cjs.prod.js +0 -152
- package/dist/timeout-4180303d.esm.js +0 -22
- package/dist/upstreamPullRequest-be86e51c.esm.js +0 -71
- package/dist/upstreamPullRequest-d2eaf7f5.cjs.prod.js +0 -79
- package/dist/upstreamPullRequest-f986731f.cjs.dev.js +0 -79
- package/dist/upstreamPullStrategy-08e7185f.cjs.prod.js +0 -81
- package/dist/upstreamPullStrategy-29c0b698.cjs.dev.js +0 -81
- package/dist/upstreamPullStrategy-d1505fa4.esm.js +0 -71
|
@@ -1,2877 +0,0 @@
|
|
|
1
|
-
import { f as fail$2, a as failureOrCause, d as die$2, m as map$4, b as isInterrupted, c as isDieType, R as RuntimeException } from './Cause-8be0b9a6.esm.js';
|
|
2
|
-
import { f as fromIterable, u as unsafeGet$1, e as empty, i as isEmpty, l as unsafeFromArray, b as appendAll, c as append, n as toReadonlyArray, d as drop$1, z as flatten$2, s as map$5, A as dropWhile$1, g as filter, o as of, B as splitAt, h as isNonEmpty, C as last$1, y as reduce } from './Chunk-98371336.esm.js';
|
|
3
|
-
import { a as currentTimeMillis } from './Clock-ab907687.esm.js';
|
|
4
|
-
import { m as millis } from './Duration-5e9f2327.esm.js';
|
|
5
|
-
import { i as isEffect, e as unit$1, g as ignore, z as zipWith$1, h as exit, s as sync$2, p as provide, m as matchCauseEffect, j as zipRight$3, k as flatMap$2, l as suspend$2, n as forkDaemon, o as ensuring$2, q as uninterruptible, r as map$2, t as zip$2, v as forEach$1, w as succeed$3, x as scoped$1, u as uninterruptibleMask, y as scope, A as forkScoped, B as addFinalizer, C as zipLeft$2, D as all$1, F as dieMessage$1, c as catchAllCause$1, G as acquireUseRelease$1, H as intoDeferred, I as tapErrorCause, f as failCause$3, J as tap, K as context$2, L as matchCause, d as flatten$1, M as gen, N as acquireRelease, O as makeSemaphore, P as interruptible, Q as asUnit$1, R as raceFirst, S as forever, T as raceWith$1, b as as$2, U as race$1, V as when, W as repeatWhile, X as never$2, Y as withSpanScoped, Z as repeatUntil, _ as takeWhile, $ as contextWith$2, a0 as filter$1, a1 as dropUntil$1, a2 as dropWhile$2 } from './Effect-d5910dae.esm.js';
|
|
6
|
-
import { b as match, l as left, r as right, m as merge$2 } from './Either-09270bbc.esm.js';
|
|
7
|
-
import { e as isFailure, z as zipRight$2, d as die$1, m as match$1, s as succeed$2, a as failCause$2, g as all, u as unit$2, h as map$3, j as zip$3 } from './Exit-e31718e3.esm.js';
|
|
8
|
-
import { d as dual, i as identity, b as constVoid, p as pipe, c as constTrue } from './Function-52fb7d21.esm.js';
|
|
9
|
-
import { e as empty$1, j as has, u as unsafeGet$2, s as set$1 } from './HashMap-e644e23b.esm.js';
|
|
10
|
-
import { e as empty$2, h as has$1, a as add$1 } from './HashSet-dff2542b.esm.js';
|
|
11
|
-
import { s as subscribe, b as bounded$1 } from './Hub-9f3d5c5d.esm.js';
|
|
12
|
-
import { n as none, i as isSome, g as getOrElse, b as match$2, s as some$1, a as isNone, o as orElse$2 } from './Option-1d073850.esm.js';
|
|
13
|
-
import { p as pipeArguments } from './Pipeable-fe51dc02.esm.js';
|
|
14
|
-
import { t as take$1, b as bounded, s as shutdown, o as offer, u as unbounded, a as size, c as offerAll } from './Queue-bbebbeda.esm.js';
|
|
15
|
-
import { X as span } from './ReadonlyArray-199ff80e.esm.js';
|
|
16
|
-
import { m as make$1, g as get, s as set, u as update, a as modify } from './Ref-9a9de951.esm.js';
|
|
17
|
-
import { b as add, m as merge$1, c as make$4, u as unsafeGet } from './Context-48179faa.esm.js';
|
|
18
|
-
import { s as succeed$4, _ as _await, m as make, f as failCause$4, i as isDone } from './Deferred-554d3588.esm.js';
|
|
19
|
-
import { e as equals } from './Equal-7d4ae7e7.esm.js';
|
|
20
|
-
import { i as interrupt, a as inheritAll, j as join, _ as _await$1 } from './Fiber-38517971.esm.js';
|
|
21
|
-
import { b as build, m as merge, c as context$3 } from './Layer-f7be72db.esm.js';
|
|
22
|
-
import { f as fork, a as addFinalizer$1, m as make$3, e as extend, c as close } from './Scope-0ffde3bb.esm.js';
|
|
23
|
-
import { a as sequential } from './ExecutionStrategy-c6f7c490.esm.js';
|
|
24
|
-
import { C as Continue, O as OP_YIELD, a as OP_CLOSE, b as OP_CONTINUE } from './childExecutorDecision-49f0f19c.esm.js';
|
|
25
|
-
import { P as PullAfterNext, O as OP_PULL_AFTER_ALL_ENQUEUED, a as OP_PULL_AFTER_NEXT } from './upstreamPullStrategy-d1505fa4.esm.js';
|
|
26
|
-
import { N as NoUpstream, P as Pulled } from './upstreamPullRequest-be86e51c.esm.js';
|
|
27
|
-
import { D as Done$1, A as Await, O as OP_DONE$1 } from './mergeDecision-32146c34.esm.js';
|
|
28
|
-
import { B as BothRunning, O as OP_RIGHT_DONE, R as RightDone, a as OP_LEFT_DONE, L as LeftDone, b as OP_BOTH_RUNNING } from './mergeState-21728f0b.esm.js';
|
|
29
|
-
import { m as match$3, B as BackPressure } from './mergeStrategy-84dd9011.esm.js';
|
|
30
|
-
import { m as make$2 } from './singleProducerAsyncInput-c67ef1c6.esm.js';
|
|
31
|
-
|
|
32
|
-
/** @internal */
|
|
33
|
-
const OP_CONTINUATION_K = "ContinuationK";
|
|
34
|
-
|
|
35
|
-
/** @internal */
|
|
36
|
-
|
|
37
|
-
/** @internal */
|
|
38
|
-
const OP_CONTINUATION_FINALIZER = "ContinuationFinalizer";
|
|
39
|
-
|
|
40
|
-
/** @internal */
|
|
41
|
-
|
|
42
|
-
/** @internal */
|
|
43
|
-
const ContinuationTypeId = /*#__PURE__*/Symbol.for("effect/ChannelContinuation");
|
|
44
|
-
|
|
45
|
-
/** @internal */
|
|
46
|
-
|
|
47
|
-
/** @internal */
|
|
48
|
-
|
|
49
|
-
/** @internal */
|
|
50
|
-
|
|
51
|
-
/** @internal */
|
|
52
|
-
|
|
53
|
-
/** @internal */
|
|
54
|
-
|
|
55
|
-
/** @internal */
|
|
56
|
-
|
|
57
|
-
/** @internal */
|
|
58
|
-
|
|
59
|
-
/** @internal */
|
|
60
|
-
|
|
61
|
-
/** @internal */
|
|
62
|
-
const continuationVariance = {
|
|
63
|
-
_Env: _ => _,
|
|
64
|
-
_InErr: _ => _,
|
|
65
|
-
_InElem: _ => _,
|
|
66
|
-
_InDone: _ => _,
|
|
67
|
-
_OutErr: _ => _,
|
|
68
|
-
_OutDone: _ => _,
|
|
69
|
-
_OutErr2: _ => _,
|
|
70
|
-
_OutElem: _ => _,
|
|
71
|
-
_OutDone2: _ => _
|
|
72
|
-
};
|
|
73
|
-
|
|
74
|
-
/** @internal */
|
|
75
|
-
class ContinuationKImpl {
|
|
76
|
-
_tag = OP_CONTINUATION_K;
|
|
77
|
-
[ContinuationTypeId] = continuationVariance;
|
|
78
|
-
constructor(onSuccess, onHalt) {
|
|
79
|
-
this.onSuccess = onSuccess;
|
|
80
|
-
this.onHalt = onHalt;
|
|
81
|
-
}
|
|
82
|
-
onExit(exit) {
|
|
83
|
-
return isFailure(exit) ? this.onHalt(exit.cause) : this.onSuccess(exit.value);
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
/** @internal */
|
|
88
|
-
class ContinuationFinalizerImpl {
|
|
89
|
-
_tag = OP_CONTINUATION_FINALIZER;
|
|
90
|
-
[ContinuationTypeId] = continuationVariance;
|
|
91
|
-
constructor(finalizer) {
|
|
92
|
-
this.finalizer = finalizer;
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
/** @internal */
|
|
97
|
-
const OP_BRACKET_OUT = "BracketOut";
|
|
98
|
-
|
|
99
|
-
/** @internal */
|
|
100
|
-
|
|
101
|
-
/** @internal */
|
|
102
|
-
const OP_BRIDGE = "Bridge";
|
|
103
|
-
|
|
104
|
-
/** @internal */
|
|
105
|
-
|
|
106
|
-
/** @internal */
|
|
107
|
-
const OP_CONCAT_ALL = "ConcatAll";
|
|
108
|
-
|
|
109
|
-
/** @internal */
|
|
110
|
-
|
|
111
|
-
/** @internal */
|
|
112
|
-
const OP_EMIT$2 = "Emit";
|
|
113
|
-
|
|
114
|
-
/** @internal */
|
|
115
|
-
|
|
116
|
-
/** @internal */
|
|
117
|
-
const OP_ENSURING = "Ensuring";
|
|
118
|
-
|
|
119
|
-
/** @internal */
|
|
120
|
-
|
|
121
|
-
/** @internal */
|
|
122
|
-
const OP_FAIL = "Fail";
|
|
123
|
-
|
|
124
|
-
/** @internal */
|
|
125
|
-
|
|
126
|
-
/** @internal */
|
|
127
|
-
const OP_FOLD = "Fold";
|
|
128
|
-
|
|
129
|
-
/** @internal */
|
|
130
|
-
|
|
131
|
-
/** @internal */
|
|
132
|
-
const OP_FROM_EFFECT$1 = "FromEffect";
|
|
133
|
-
|
|
134
|
-
/** @internal */
|
|
135
|
-
|
|
136
|
-
/** @internal */
|
|
137
|
-
const OP_PIPE_TO = "PipeTo";
|
|
138
|
-
|
|
139
|
-
/** @internal */
|
|
140
|
-
|
|
141
|
-
/** @internal */
|
|
142
|
-
const OP_PROVIDE = "Provide";
|
|
143
|
-
|
|
144
|
-
/** @internal */
|
|
145
|
-
|
|
146
|
-
/** @internal */
|
|
147
|
-
const OP_READ$1 = "Read";
|
|
148
|
-
|
|
149
|
-
/** @internal */
|
|
150
|
-
|
|
151
|
-
/** @internal */
|
|
152
|
-
const OP_SUCCEED = "Succeed";
|
|
153
|
-
|
|
154
|
-
/** @internal */
|
|
155
|
-
|
|
156
|
-
/** @internal */
|
|
157
|
-
const OP_SUCCEED_NOW = "SucceedNow";
|
|
158
|
-
|
|
159
|
-
/** @internal */
|
|
160
|
-
|
|
161
|
-
/** @internal */
|
|
162
|
-
const OP_SUSPEND = "Suspend";
|
|
163
|
-
|
|
164
|
-
/** @internal */
|
|
165
|
-
|
|
166
|
-
/** @internal */
|
|
167
|
-
const ChannelSymbolKey = "effect/Channel";
|
|
168
|
-
|
|
169
|
-
/** @internal */
|
|
170
|
-
const ChannelTypeId = /*#__PURE__*/Symbol.for(ChannelSymbolKey);
|
|
171
|
-
|
|
172
|
-
/** @internal */
|
|
173
|
-
const channelVariance = {
|
|
174
|
-
_Env: _ => _,
|
|
175
|
-
_InErr: _ => _,
|
|
176
|
-
_InElem: _ => _,
|
|
177
|
-
_InDone: _ => _,
|
|
178
|
-
_OutErr: _ => _,
|
|
179
|
-
_OutElem: _ => _,
|
|
180
|
-
_OutDone: _ => _
|
|
181
|
-
};
|
|
182
|
-
|
|
183
|
-
/** @internal */
|
|
184
|
-
const proto$1 = {
|
|
185
|
-
[ChannelTypeId]: channelVariance,
|
|
186
|
-
pipe() {
|
|
187
|
-
return pipeArguments(this, arguments);
|
|
188
|
-
}
|
|
189
|
-
};
|
|
190
|
-
|
|
191
|
-
/** @internal */
|
|
192
|
-
|
|
193
|
-
/** @internal */
|
|
194
|
-
|
|
195
|
-
/** @internal */
|
|
196
|
-
|
|
197
|
-
/** @internal */
|
|
198
|
-
|
|
199
|
-
/** @internal */
|
|
200
|
-
|
|
201
|
-
/** @internal */
|
|
202
|
-
|
|
203
|
-
/** @internal */
|
|
204
|
-
|
|
205
|
-
/** @internal */
|
|
206
|
-
|
|
207
|
-
/** @internal */
|
|
208
|
-
|
|
209
|
-
/** @internal */
|
|
210
|
-
|
|
211
|
-
/** @internal */
|
|
212
|
-
|
|
213
|
-
/** @internal */
|
|
214
|
-
|
|
215
|
-
/** @internal */
|
|
216
|
-
|
|
217
|
-
/** @internal */
|
|
218
|
-
|
|
219
|
-
/** @internal */
|
|
220
|
-
|
|
221
|
-
/** @internal */
|
|
222
|
-
|
|
223
|
-
/** @internal */
|
|
224
|
-
const isChannel = u => typeof u === "object" && u != null && ChannelTypeId in u || isEffect(u);
|
|
225
|
-
|
|
226
|
-
/** @internal */
|
|
227
|
-
const acquireReleaseOut = /*#__PURE__*/dual(2, (self, release) => {
|
|
228
|
-
const op = Object.create(proto$1);
|
|
229
|
-
op._tag = OP_BRACKET_OUT;
|
|
230
|
-
op.acquire = () => self;
|
|
231
|
-
op.finalizer = release;
|
|
232
|
-
return op;
|
|
233
|
-
});
|
|
234
|
-
|
|
235
|
-
/** @internal */
|
|
236
|
-
const catchAllCause = /*#__PURE__*/dual(2, (self, f) => {
|
|
237
|
-
const op = Object.create(proto$1);
|
|
238
|
-
op._tag = OP_FOLD;
|
|
239
|
-
op.channel = self;
|
|
240
|
-
op.k = new ContinuationKImpl(succeed$1, f);
|
|
241
|
-
return op;
|
|
242
|
-
});
|
|
243
|
-
|
|
244
|
-
/** @internal */
|
|
245
|
-
const collectElements = self => {
|
|
246
|
-
return suspend$1(() => {
|
|
247
|
-
const builder = [];
|
|
248
|
-
return flatMap$1(pipeTo(self, collectElementsReader(builder)), value => sync$1(() => [fromIterable(builder), value]));
|
|
249
|
-
});
|
|
250
|
-
};
|
|
251
|
-
|
|
252
|
-
/** @internal */
|
|
253
|
-
const collectElementsReader = builder => readWith({
|
|
254
|
-
onInput: outElem => flatMap$1(sync$1(() => {
|
|
255
|
-
builder.push(outElem);
|
|
256
|
-
}), () => collectElementsReader(builder)),
|
|
257
|
-
onFailure: fail$1,
|
|
258
|
-
onDone: succeedNow
|
|
259
|
-
});
|
|
260
|
-
|
|
261
|
-
/** @internal */
|
|
262
|
-
const concatAll = channels => concatAllWith(channels, constVoid, constVoid);
|
|
263
|
-
|
|
264
|
-
/** @internal */
|
|
265
|
-
const concatAllWith = (channels, f, g) => {
|
|
266
|
-
const op = Object.create(proto$1);
|
|
267
|
-
op._tag = OP_CONCAT_ALL;
|
|
268
|
-
op.combineInners = f;
|
|
269
|
-
op.combineAll = g;
|
|
270
|
-
op.onPull = () => PullAfterNext(none());
|
|
271
|
-
op.onEmit = () => Continue;
|
|
272
|
-
op.value = () => channels;
|
|
273
|
-
op.k = identity;
|
|
274
|
-
return op;
|
|
275
|
-
};
|
|
276
|
-
|
|
277
|
-
/** @internal */
|
|
278
|
-
const concatMapWith = /*#__PURE__*/dual(4, (self, f, g, h) => {
|
|
279
|
-
const op = Object.create(proto$1);
|
|
280
|
-
op._tag = OP_CONCAT_ALL;
|
|
281
|
-
op.combineInners = g;
|
|
282
|
-
op.combineAll = h;
|
|
283
|
-
op.onPull = () => PullAfterNext(none());
|
|
284
|
-
op.onEmit = () => Continue;
|
|
285
|
-
op.value = () => self;
|
|
286
|
-
op.k = f;
|
|
287
|
-
return op;
|
|
288
|
-
});
|
|
289
|
-
|
|
290
|
-
/** @internal */
|
|
291
|
-
const concatMapWithCustom = /*#__PURE__*/dual(6, (self, f, g, h, onPull, onEmit) => {
|
|
292
|
-
const op = Object.create(proto$1);
|
|
293
|
-
op._tag = OP_CONCAT_ALL;
|
|
294
|
-
op.combineInners = g;
|
|
295
|
-
op.combineAll = h;
|
|
296
|
-
op.onPull = onPull;
|
|
297
|
-
op.onEmit = onEmit;
|
|
298
|
-
op.value = () => self;
|
|
299
|
-
op.k = f;
|
|
300
|
-
return op;
|
|
301
|
-
});
|
|
302
|
-
|
|
303
|
-
/** @internal */
|
|
304
|
-
const embedInput = /*#__PURE__*/dual(2, (self, input) => {
|
|
305
|
-
const op = Object.create(proto$1);
|
|
306
|
-
op._tag = OP_BRIDGE;
|
|
307
|
-
op.input = input;
|
|
308
|
-
op.channel = self;
|
|
309
|
-
return op;
|
|
310
|
-
});
|
|
311
|
-
|
|
312
|
-
/** @internal */
|
|
313
|
-
const ensuringWith$1 = /*#__PURE__*/dual(2, (self, finalizer) => {
|
|
314
|
-
const op = Object.create(proto$1);
|
|
315
|
-
op._tag = OP_ENSURING;
|
|
316
|
-
op.channel = self;
|
|
317
|
-
op.finalizer = finalizer;
|
|
318
|
-
return op;
|
|
319
|
-
});
|
|
320
|
-
|
|
321
|
-
/** @internal */
|
|
322
|
-
const fail$1 = error => failCause$1(fail$2(error));
|
|
323
|
-
|
|
324
|
-
/** @internal */
|
|
325
|
-
const failSync$1 = evaluate => failCauseSync$1(() => fail$2(evaluate()));
|
|
326
|
-
|
|
327
|
-
/** @internal */
|
|
328
|
-
const failCause$1 = cause => failCauseSync$1(() => cause);
|
|
329
|
-
|
|
330
|
-
/** @internal */
|
|
331
|
-
const failCauseSync$1 = evaluate => {
|
|
332
|
-
const op = Object.create(proto$1);
|
|
333
|
-
op._tag = OP_FAIL;
|
|
334
|
-
op.error = evaluate;
|
|
335
|
-
return op;
|
|
336
|
-
};
|
|
337
|
-
|
|
338
|
-
/** @internal */
|
|
339
|
-
const flatMap$1 = /*#__PURE__*/dual(2, (self, f) => {
|
|
340
|
-
const op = Object.create(proto$1);
|
|
341
|
-
op._tag = OP_FOLD;
|
|
342
|
-
op.channel = self;
|
|
343
|
-
op.k = new ContinuationKImpl(f, failCause$1);
|
|
344
|
-
return op;
|
|
345
|
-
});
|
|
346
|
-
|
|
347
|
-
/** @internal */
|
|
348
|
-
const foldCauseChannel = /*#__PURE__*/dual(2, (self, options) => {
|
|
349
|
-
const op = Object.create(proto$1);
|
|
350
|
-
op._tag = OP_FOLD;
|
|
351
|
-
op.channel = self;
|
|
352
|
-
op.k = new ContinuationKImpl(options.onSuccess, options.onFailure);
|
|
353
|
-
return op;
|
|
354
|
-
});
|
|
355
|
-
|
|
356
|
-
/** @internal */
|
|
357
|
-
const fromEffect$1 = effect => {
|
|
358
|
-
const op = Object.create(proto$1);
|
|
359
|
-
op._tag = OP_FROM_EFFECT$1;
|
|
360
|
-
op.effect = () => effect;
|
|
361
|
-
return op;
|
|
362
|
-
};
|
|
363
|
-
|
|
364
|
-
/** @internal */
|
|
365
|
-
const pipeTo = /*#__PURE__*/dual(2, (self, that) => {
|
|
366
|
-
const op = Object.create(proto$1);
|
|
367
|
-
op._tag = OP_PIPE_TO;
|
|
368
|
-
op.left = () => self;
|
|
369
|
-
op.right = () => that;
|
|
370
|
-
return op;
|
|
371
|
-
});
|
|
372
|
-
|
|
373
|
-
/** @internal */
|
|
374
|
-
const provideContext$1 = /*#__PURE__*/dual(2, (self, env) => {
|
|
375
|
-
const op = Object.create(proto$1);
|
|
376
|
-
op._tag = OP_PROVIDE;
|
|
377
|
-
op.context = () => env;
|
|
378
|
-
op.inner = self;
|
|
379
|
-
return op;
|
|
380
|
-
});
|
|
381
|
-
|
|
382
|
-
/** @internal */
|
|
383
|
-
const readOrFail = error => {
|
|
384
|
-
const op = Object.create(proto$1);
|
|
385
|
-
op._tag = OP_READ$1;
|
|
386
|
-
op.more = succeed$1;
|
|
387
|
-
op.done = new ContinuationKImpl(() => fail$1(error), () => fail$1(error));
|
|
388
|
-
return op;
|
|
389
|
-
};
|
|
390
|
-
|
|
391
|
-
/** @internal */
|
|
392
|
-
const readWith = options => readWithCause({
|
|
393
|
-
onInput: options.onInput,
|
|
394
|
-
onFailure: cause => match(failureOrCause(cause), {
|
|
395
|
-
onLeft: options.onFailure,
|
|
396
|
-
onRight: failCause$1
|
|
397
|
-
}),
|
|
398
|
-
onDone: options.onDone
|
|
399
|
-
});
|
|
400
|
-
|
|
401
|
-
/** @internal */
|
|
402
|
-
const readWithCause = options => {
|
|
403
|
-
const op = Object.create(proto$1);
|
|
404
|
-
op._tag = OP_READ$1;
|
|
405
|
-
op.more = options.onInput;
|
|
406
|
-
op.done = new ContinuationKImpl(options.onDone, options.onFailure);
|
|
407
|
-
return op;
|
|
408
|
-
};
|
|
409
|
-
|
|
410
|
-
/** @internal */
|
|
411
|
-
const succeed$1 = value => sync$1(() => value);
|
|
412
|
-
|
|
413
|
-
/** @internal */
|
|
414
|
-
const succeedNow = result => {
|
|
415
|
-
const op = Object.create(proto$1);
|
|
416
|
-
op._tag = OP_SUCCEED_NOW;
|
|
417
|
-
op.terminal = result;
|
|
418
|
-
return op;
|
|
419
|
-
};
|
|
420
|
-
|
|
421
|
-
/** @internal */
|
|
422
|
-
const suspend$1 = evaluate => {
|
|
423
|
-
const op = Object.create(proto$1);
|
|
424
|
-
op._tag = OP_SUSPEND;
|
|
425
|
-
op.channel = evaluate;
|
|
426
|
-
return op;
|
|
427
|
-
};
|
|
428
|
-
const sync$1 = evaluate => {
|
|
429
|
-
const op = Object.create(proto$1);
|
|
430
|
-
op._tag = OP_SUCCEED;
|
|
431
|
-
op.evaluate = evaluate;
|
|
432
|
-
return op;
|
|
433
|
-
};
|
|
434
|
-
|
|
435
|
-
/** @internal */
|
|
436
|
-
const unit = /*#__PURE__*/succeedNow(void 0);
|
|
437
|
-
|
|
438
|
-
/** @internal */
|
|
439
|
-
const write = out => {
|
|
440
|
-
const op = Object.create(proto$1);
|
|
441
|
-
op._tag = OP_EMIT$2;
|
|
442
|
-
op.out = out;
|
|
443
|
-
return op;
|
|
444
|
-
};
|
|
445
|
-
|
|
446
|
-
/** @internal */
|
|
447
|
-
const OP_DONE = "Done";
|
|
448
|
-
|
|
449
|
-
/** @internal */
|
|
450
|
-
|
|
451
|
-
/** @internal */
|
|
452
|
-
const OP_EMIT$1 = "Emit";
|
|
453
|
-
|
|
454
|
-
/** @internal */
|
|
455
|
-
|
|
456
|
-
/** @internal */
|
|
457
|
-
const OP_FROM_EFFECT = "FromEffect";
|
|
458
|
-
|
|
459
|
-
/** @internal */
|
|
460
|
-
|
|
461
|
-
/** @internal */
|
|
462
|
-
const OP_READ = "Read";
|
|
463
|
-
|
|
464
|
-
/** @internal */
|
|
465
|
-
|
|
466
|
-
/** @internal */
|
|
467
|
-
const ChannelStateTypeId = /*#__PURE__*/Symbol.for("effect/ChannelState");
|
|
468
|
-
|
|
469
|
-
/** @internal */
|
|
470
|
-
|
|
471
|
-
/** @internal */
|
|
472
|
-
|
|
473
|
-
/** @internal */
|
|
474
|
-
|
|
475
|
-
/** @internal */
|
|
476
|
-
const channelStateVariance = {
|
|
477
|
-
_R: _ => _,
|
|
478
|
-
_E: _ => _
|
|
479
|
-
};
|
|
480
|
-
|
|
481
|
-
/** @internal */
|
|
482
|
-
const proto = {
|
|
483
|
-
[ChannelStateTypeId]: channelStateVariance
|
|
484
|
-
};
|
|
485
|
-
|
|
486
|
-
/** @internal */
|
|
487
|
-
|
|
488
|
-
/** @internal */
|
|
489
|
-
|
|
490
|
-
/** @internal */
|
|
491
|
-
|
|
492
|
-
/** @internal */
|
|
493
|
-
|
|
494
|
-
/** @internal */
|
|
495
|
-
|
|
496
|
-
/** @internal */
|
|
497
|
-
|
|
498
|
-
/** @internal */
|
|
499
|
-
const Done = () => {
|
|
500
|
-
const op = Object.create(proto);
|
|
501
|
-
op._tag = OP_DONE;
|
|
502
|
-
return op;
|
|
503
|
-
};
|
|
504
|
-
|
|
505
|
-
/** @internal */
|
|
506
|
-
const Emit$1 = () => {
|
|
507
|
-
const op = Object.create(proto);
|
|
508
|
-
op._tag = OP_EMIT$1;
|
|
509
|
-
return op;
|
|
510
|
-
};
|
|
511
|
-
|
|
512
|
-
/** @internal */
|
|
513
|
-
const FromEffect = effect => {
|
|
514
|
-
const op = Object.create(proto);
|
|
515
|
-
op._tag = OP_FROM_EFFECT;
|
|
516
|
-
op.effect = effect;
|
|
517
|
-
return op;
|
|
518
|
-
};
|
|
519
|
-
|
|
520
|
-
/** @internal */
|
|
521
|
-
const Read = (upstream, onEffect, onEmit, onDone) => {
|
|
522
|
-
const op = Object.create(proto);
|
|
523
|
-
op._tag = OP_READ;
|
|
524
|
-
op.upstream = upstream;
|
|
525
|
-
op.onEffect = onEffect;
|
|
526
|
-
op.onEmit = onEmit;
|
|
527
|
-
op.onDone = onDone;
|
|
528
|
-
return op;
|
|
529
|
-
};
|
|
530
|
-
|
|
531
|
-
/** @internal */
|
|
532
|
-
const isFromEffect = self => self._tag === OP_FROM_EFFECT;
|
|
533
|
-
|
|
534
|
-
/** @internal */
|
|
535
|
-
const effect = self => isFromEffect(self) ? self.effect : unit$1;
|
|
536
|
-
|
|
537
|
-
/** @internal */
|
|
538
|
-
const effectOrUndefinedIgnored = self => isFromEffect(self) ? ignore(self.effect) : undefined;
|
|
539
|
-
|
|
540
|
-
/** @internal */
|
|
541
|
-
|
|
542
|
-
/** @internal */
|
|
543
|
-
|
|
544
|
-
/** @internal */
|
|
545
|
-
const OP_PULL_FROM_CHILD = "PullFromChild";
|
|
546
|
-
|
|
547
|
-
/** @internal */
|
|
548
|
-
|
|
549
|
-
/** @internal */
|
|
550
|
-
const OP_PULL_FROM_UPSTREAM = "PullFromUpstream";
|
|
551
|
-
|
|
552
|
-
/** @internal */
|
|
553
|
-
|
|
554
|
-
/** @internal */
|
|
555
|
-
const OP_DRAIN_CHILD_EXECUTORS = "DrainChildExecutors";
|
|
556
|
-
|
|
557
|
-
/** @internal */
|
|
558
|
-
|
|
559
|
-
/** @internal */
|
|
560
|
-
const OP_EMIT = "Emit";
|
|
561
|
-
|
|
562
|
-
/** @internal */
|
|
563
|
-
|
|
564
|
-
/**
|
|
565
|
-
* Execute the `childExecutor` and on each emitted value, decide what to do by
|
|
566
|
-
* `onEmit`.
|
|
567
|
-
*
|
|
568
|
-
* @internal
|
|
569
|
-
*/
|
|
570
|
-
class PullFromChild {
|
|
571
|
-
_tag = OP_PULL_FROM_CHILD;
|
|
572
|
-
constructor(childExecutor, parentSubexecutor, onEmit) {
|
|
573
|
-
this.childExecutor = childExecutor;
|
|
574
|
-
this.parentSubexecutor = parentSubexecutor;
|
|
575
|
-
this.onEmit = onEmit;
|
|
576
|
-
}
|
|
577
|
-
close(exit$1) {
|
|
578
|
-
const fin1 = this.childExecutor.close(exit$1);
|
|
579
|
-
const fin2 = this.parentSubexecutor.close(exit$1);
|
|
580
|
-
if (fin1 !== undefined && fin2 !== undefined) {
|
|
581
|
-
return zipWith$1(exit(fin1), exit(fin2), (exit1, exit2) => pipe(exit1, zipRight$2(exit2)));
|
|
582
|
-
} else if (fin1 !== undefined) {
|
|
583
|
-
return fin1;
|
|
584
|
-
} else if (fin2 !== undefined) {
|
|
585
|
-
return fin2;
|
|
586
|
-
} else {
|
|
587
|
-
return undefined;
|
|
588
|
-
}
|
|
589
|
-
}
|
|
590
|
-
enqueuePullFromChild(_child) {
|
|
591
|
-
return this;
|
|
592
|
-
}
|
|
593
|
-
}
|
|
594
|
-
|
|
595
|
-
/**
|
|
596
|
-
* Execute `upstreamExecutor` and for each emitted element, spawn a child
|
|
597
|
-
* channel and continue with processing it by `PullFromChild`.
|
|
598
|
-
*
|
|
599
|
-
* @internal
|
|
600
|
-
*/
|
|
601
|
-
class PullFromUpstream {
|
|
602
|
-
_tag = OP_PULL_FROM_UPSTREAM;
|
|
603
|
-
constructor(upstreamExecutor, createChild, lastDone, activeChildExecutors, combineChildResults, combineWithChildResult, onPull, onEmit) {
|
|
604
|
-
this.upstreamExecutor = upstreamExecutor;
|
|
605
|
-
this.createChild = createChild;
|
|
606
|
-
this.lastDone = lastDone;
|
|
607
|
-
this.activeChildExecutors = activeChildExecutors;
|
|
608
|
-
this.combineChildResults = combineChildResults;
|
|
609
|
-
this.combineWithChildResult = combineWithChildResult;
|
|
610
|
-
this.onPull = onPull;
|
|
611
|
-
this.onEmit = onEmit;
|
|
612
|
-
}
|
|
613
|
-
close(exit$1) {
|
|
614
|
-
const fin1 = this.upstreamExecutor.close(exit$1);
|
|
615
|
-
const fins = [...this.activeChildExecutors.map(child => child !== undefined ? child.childExecutor.close(exit$1) : undefined), fin1];
|
|
616
|
-
const result = fins.reduce((acc, next) => {
|
|
617
|
-
if (acc !== undefined && next !== undefined) {
|
|
618
|
-
return zipWith$1(acc, exit(next), (exit1, exit2) => zipRight$2(exit1, exit2));
|
|
619
|
-
} else if (acc !== undefined) {
|
|
620
|
-
return acc;
|
|
621
|
-
} else if (next !== undefined) {
|
|
622
|
-
return exit(next);
|
|
623
|
-
} else {
|
|
624
|
-
return undefined;
|
|
625
|
-
}
|
|
626
|
-
}, undefined);
|
|
627
|
-
return result === undefined ? result : result;
|
|
628
|
-
}
|
|
629
|
-
enqueuePullFromChild(child) {
|
|
630
|
-
return new PullFromUpstream(this.upstreamExecutor, this.createChild, this.lastDone, [...this.activeChildExecutors, child], this.combineChildResults, this.combineWithChildResult, this.onPull, this.onEmit);
|
|
631
|
-
}
|
|
632
|
-
}
|
|
633
|
-
|
|
634
|
-
/**
|
|
635
|
-
* Transformed from `PullFromUpstream` when upstream has finished but there
|
|
636
|
-
* are still active child executors.
|
|
637
|
-
*
|
|
638
|
-
* @internal
|
|
639
|
-
*/
|
|
640
|
-
class DrainChildExecutors {
|
|
641
|
-
_tag = OP_DRAIN_CHILD_EXECUTORS;
|
|
642
|
-
constructor(upstreamExecutor, lastDone, activeChildExecutors, upstreamDone, combineChildResults, combineWithChildResult, onPull) {
|
|
643
|
-
this.upstreamExecutor = upstreamExecutor;
|
|
644
|
-
this.lastDone = lastDone;
|
|
645
|
-
this.activeChildExecutors = activeChildExecutors;
|
|
646
|
-
this.upstreamDone = upstreamDone;
|
|
647
|
-
this.combineChildResults = combineChildResults;
|
|
648
|
-
this.combineWithChildResult = combineWithChildResult;
|
|
649
|
-
this.onPull = onPull;
|
|
650
|
-
}
|
|
651
|
-
close(exit$1) {
|
|
652
|
-
const fin1 = this.upstreamExecutor.close(exit$1);
|
|
653
|
-
const fins = [...this.activeChildExecutors.map(child => child !== undefined ? child.childExecutor.close(exit$1) : undefined), fin1];
|
|
654
|
-
const result = fins.reduce((acc, next) => {
|
|
655
|
-
if (acc !== undefined && next !== undefined) {
|
|
656
|
-
return zipWith$1(acc, exit(next), (exit1, exit2) => zipRight$2(exit1, exit2));
|
|
657
|
-
} else if (acc !== undefined) {
|
|
658
|
-
return acc;
|
|
659
|
-
} else if (next !== undefined) {
|
|
660
|
-
return exit(next);
|
|
661
|
-
} else {
|
|
662
|
-
return undefined;
|
|
663
|
-
}
|
|
664
|
-
}, undefined);
|
|
665
|
-
return result === undefined ? result : result;
|
|
666
|
-
}
|
|
667
|
-
enqueuePullFromChild(child) {
|
|
668
|
-
return new DrainChildExecutors(this.upstreamExecutor, this.lastDone, [...this.activeChildExecutors, child], this.upstreamDone, this.combineChildResults, this.combineWithChildResult, this.onPull);
|
|
669
|
-
}
|
|
670
|
-
}
|
|
671
|
-
|
|
672
|
-
/** @internal */
|
|
673
|
-
class Emit {
|
|
674
|
-
_tag = OP_EMIT;
|
|
675
|
-
constructor(value, next) {
|
|
676
|
-
this.value = value;
|
|
677
|
-
this.next = next;
|
|
678
|
-
}
|
|
679
|
-
close(exit) {
|
|
680
|
-
const result = this.next.close(exit);
|
|
681
|
-
return result === undefined ? result : result;
|
|
682
|
-
}
|
|
683
|
-
enqueuePullFromChild(_child) {
|
|
684
|
-
return this;
|
|
685
|
-
}
|
|
686
|
-
}
|
|
687
|
-
|
|
688
|
-
/** @internal */
|
|
689
|
-
|
|
690
|
-
/** @internal */
|
|
691
|
-
|
|
692
|
-
/** @internal */
|
|
693
|
-
|
|
694
|
-
class ChannelExecutor {
|
|
695
|
-
_activeSubexecutor = undefined;
|
|
696
|
-
_cancelled = undefined;
|
|
697
|
-
_closeLastSubstream = undefined;
|
|
698
|
-
_done = undefined;
|
|
699
|
-
_doneStack = [];
|
|
700
|
-
_emitted = undefined;
|
|
701
|
-
_input = undefined;
|
|
702
|
-
_inProgressFinalizer = undefined;
|
|
703
|
-
constructor(initialChannel, providedEnv, executeCloseLastSubstream) {
|
|
704
|
-
this._currentChannel = initialChannel;
|
|
705
|
-
this._executeCloseLastSubstream = executeCloseLastSubstream;
|
|
706
|
-
this._providedEnv = providedEnv;
|
|
707
|
-
}
|
|
708
|
-
run() {
|
|
709
|
-
let result = undefined;
|
|
710
|
-
while (result === undefined) {
|
|
711
|
-
if (this._cancelled !== undefined) {
|
|
712
|
-
result = this.processCancellation();
|
|
713
|
-
} else if (this._activeSubexecutor !== undefined) {
|
|
714
|
-
result = this.runSubexecutor();
|
|
715
|
-
} else {
|
|
716
|
-
try {
|
|
717
|
-
if (this._currentChannel === undefined) {
|
|
718
|
-
result = Done();
|
|
719
|
-
} else {
|
|
720
|
-
if (isEffect(this._currentChannel)) {
|
|
721
|
-
this._currentChannel = fromEffect$1(this._currentChannel);
|
|
722
|
-
} else {
|
|
723
|
-
switch (this._currentChannel._tag) {
|
|
724
|
-
case OP_BRACKET_OUT:
|
|
725
|
-
{
|
|
726
|
-
result = this.runBracketOut(this._currentChannel);
|
|
727
|
-
break;
|
|
728
|
-
}
|
|
729
|
-
case OP_BRIDGE:
|
|
730
|
-
{
|
|
731
|
-
const bridgeInput = this._currentChannel.input;
|
|
732
|
-
|
|
733
|
-
// PipeTo(left, Bridge(queue, channel))
|
|
734
|
-
// In a fiber: repeatedly run left and push its outputs to the queue
|
|
735
|
-
// Add a finalizer to interrupt the fiber and close the executor
|
|
736
|
-
this._currentChannel = this._currentChannel.channel;
|
|
737
|
-
if (this._input !== undefined) {
|
|
738
|
-
const inputExecutor = this._input;
|
|
739
|
-
this._input = undefined;
|
|
740
|
-
const drainer = () => flatMap$2(bridgeInput.awaitRead(), () => suspend$2(() => {
|
|
741
|
-
const state = inputExecutor.run();
|
|
742
|
-
switch (state._tag) {
|
|
743
|
-
case OP_DONE:
|
|
744
|
-
{
|
|
745
|
-
return match$1(inputExecutor.getDone(), {
|
|
746
|
-
onFailure: cause => bridgeInput.error(cause),
|
|
747
|
-
onSuccess: value => bridgeInput.done(value)
|
|
748
|
-
});
|
|
749
|
-
}
|
|
750
|
-
case OP_EMIT$1:
|
|
751
|
-
{
|
|
752
|
-
return flatMap$2(bridgeInput.emit(inputExecutor.getEmit()), () => drainer());
|
|
753
|
-
}
|
|
754
|
-
case OP_FROM_EFFECT:
|
|
755
|
-
{
|
|
756
|
-
return matchCauseEffect(state.effect, {
|
|
757
|
-
onFailure: cause => bridgeInput.error(cause),
|
|
758
|
-
onSuccess: () => drainer()
|
|
759
|
-
});
|
|
760
|
-
}
|
|
761
|
-
case OP_READ:
|
|
762
|
-
{
|
|
763
|
-
return readUpstream(state, () => drainer(), cause => bridgeInput.error(cause));
|
|
764
|
-
}
|
|
765
|
-
}
|
|
766
|
-
}));
|
|
767
|
-
result = FromEffect(flatMap$2(forkDaemon(drainer()), fiber => sync$2(() => this.addFinalizer(exit => flatMap$2(interrupt(fiber), () => suspend$2(() => {
|
|
768
|
-
const effect = this.restorePipe(exit, inputExecutor);
|
|
769
|
-
return effect !== undefined ? effect : unit$1;
|
|
770
|
-
}))))));
|
|
771
|
-
}
|
|
772
|
-
break;
|
|
773
|
-
}
|
|
774
|
-
case OP_CONCAT_ALL:
|
|
775
|
-
{
|
|
776
|
-
const executor = new ChannelExecutor(this._currentChannel.value(), this._providedEnv, effect => sync$2(() => {
|
|
777
|
-
const prevLastClose = this._closeLastSubstream === undefined ? unit$1 : this._closeLastSubstream;
|
|
778
|
-
this._closeLastSubstream = pipe(prevLastClose, zipRight$3(effect));
|
|
779
|
-
}));
|
|
780
|
-
executor._input = this._input;
|
|
781
|
-
const channel = this._currentChannel;
|
|
782
|
-
this._activeSubexecutor = new PullFromUpstream(executor, value => channel.k(value), undefined, [], (x, y) => channel.combineInners(x, y), (x, y) => channel.combineAll(x, y), request => channel.onPull(request), value => channel.onEmit(value));
|
|
783
|
-
this._closeLastSubstream = undefined;
|
|
784
|
-
this._currentChannel = undefined;
|
|
785
|
-
break;
|
|
786
|
-
}
|
|
787
|
-
case OP_EMIT$2:
|
|
788
|
-
{
|
|
789
|
-
this._emitted = this._currentChannel.out;
|
|
790
|
-
this._currentChannel = this._activeSubexecutor !== undefined ? undefined : unit;
|
|
791
|
-
result = Emit$1();
|
|
792
|
-
break;
|
|
793
|
-
}
|
|
794
|
-
case OP_ENSURING:
|
|
795
|
-
{
|
|
796
|
-
this.runEnsuring(this._currentChannel);
|
|
797
|
-
break;
|
|
798
|
-
}
|
|
799
|
-
case OP_FAIL:
|
|
800
|
-
{
|
|
801
|
-
result = this.doneHalt(this._currentChannel.error());
|
|
802
|
-
break;
|
|
803
|
-
}
|
|
804
|
-
case OP_FOLD:
|
|
805
|
-
{
|
|
806
|
-
this._doneStack.push(this._currentChannel.k);
|
|
807
|
-
this._currentChannel = this._currentChannel.channel;
|
|
808
|
-
break;
|
|
809
|
-
}
|
|
810
|
-
case OP_FROM_EFFECT$1:
|
|
811
|
-
{
|
|
812
|
-
const effect = this._providedEnv === undefined ? this._currentChannel.effect() : pipe(this._currentChannel.effect(), provide(this._providedEnv));
|
|
813
|
-
result = FromEffect(matchCauseEffect(effect, {
|
|
814
|
-
onFailure: cause => {
|
|
815
|
-
const state = this.doneHalt(cause);
|
|
816
|
-
return state !== undefined && isFromEffect(state) ? state.effect : unit$1;
|
|
817
|
-
},
|
|
818
|
-
onSuccess: value => {
|
|
819
|
-
const state = this.doneSucceed(value);
|
|
820
|
-
return state !== undefined && isFromEffect(state) ? state.effect : unit$1;
|
|
821
|
-
}
|
|
822
|
-
}));
|
|
823
|
-
break;
|
|
824
|
-
}
|
|
825
|
-
case OP_PIPE_TO:
|
|
826
|
-
{
|
|
827
|
-
const previousInput = this._input;
|
|
828
|
-
const leftExec = new ChannelExecutor(this._currentChannel.left(), this._providedEnv, effect => this._executeCloseLastSubstream(effect));
|
|
829
|
-
leftExec._input = previousInput;
|
|
830
|
-
this._input = leftExec;
|
|
831
|
-
this.addFinalizer(exit => {
|
|
832
|
-
const effect = this.restorePipe(exit, previousInput);
|
|
833
|
-
return effect !== undefined ? effect : unit$1;
|
|
834
|
-
});
|
|
835
|
-
this._currentChannel = this._currentChannel.right();
|
|
836
|
-
break;
|
|
837
|
-
}
|
|
838
|
-
case OP_PROVIDE:
|
|
839
|
-
{
|
|
840
|
-
const previousEnv = this._providedEnv;
|
|
841
|
-
this._providedEnv = this._currentChannel.context();
|
|
842
|
-
this._currentChannel = this._currentChannel.inner;
|
|
843
|
-
this.addFinalizer(() => sync$2(() => {
|
|
844
|
-
this._providedEnv = previousEnv;
|
|
845
|
-
}));
|
|
846
|
-
break;
|
|
847
|
-
}
|
|
848
|
-
case OP_READ$1:
|
|
849
|
-
{
|
|
850
|
-
const read = this._currentChannel;
|
|
851
|
-
result = Read(this._input, identity, emitted => {
|
|
852
|
-
try {
|
|
853
|
-
this._currentChannel = read.more(emitted);
|
|
854
|
-
} catch (error) {
|
|
855
|
-
this._currentChannel = read.done.onExit(die$1(error));
|
|
856
|
-
}
|
|
857
|
-
return undefined;
|
|
858
|
-
}, exit => {
|
|
859
|
-
const onExit = exit => {
|
|
860
|
-
return read.done.onExit(exit);
|
|
861
|
-
};
|
|
862
|
-
this._currentChannel = onExit(exit);
|
|
863
|
-
return undefined;
|
|
864
|
-
});
|
|
865
|
-
break;
|
|
866
|
-
}
|
|
867
|
-
case OP_SUCCEED:
|
|
868
|
-
{
|
|
869
|
-
result = this.doneSucceed(this._currentChannel.evaluate());
|
|
870
|
-
break;
|
|
871
|
-
}
|
|
872
|
-
case OP_SUCCEED_NOW:
|
|
873
|
-
{
|
|
874
|
-
result = this.doneSucceed(this._currentChannel.terminal);
|
|
875
|
-
break;
|
|
876
|
-
}
|
|
877
|
-
case OP_SUSPEND:
|
|
878
|
-
{
|
|
879
|
-
this._currentChannel = this._currentChannel.channel();
|
|
880
|
-
break;
|
|
881
|
-
}
|
|
882
|
-
default:
|
|
883
|
-
{
|
|
884
|
-
// @ts-expect-error
|
|
885
|
-
this._currentChannel._tag;
|
|
886
|
-
}
|
|
887
|
-
}
|
|
888
|
-
}
|
|
889
|
-
}
|
|
890
|
-
} catch (error) {
|
|
891
|
-
this._currentChannel = failCause$1(die$2(error));
|
|
892
|
-
}
|
|
893
|
-
}
|
|
894
|
-
}
|
|
895
|
-
return result;
|
|
896
|
-
}
|
|
897
|
-
getDone() {
|
|
898
|
-
return this._done;
|
|
899
|
-
}
|
|
900
|
-
getEmit() {
|
|
901
|
-
return this._emitted;
|
|
902
|
-
}
|
|
903
|
-
cancelWith(exit) {
|
|
904
|
-
this._cancelled = exit;
|
|
905
|
-
}
|
|
906
|
-
clearInProgressFinalizer() {
|
|
907
|
-
this._inProgressFinalizer = undefined;
|
|
908
|
-
}
|
|
909
|
-
storeInProgressFinalizer(finalizer) {
|
|
910
|
-
this._inProgressFinalizer = finalizer;
|
|
911
|
-
}
|
|
912
|
-
popAllFinalizers(exit) {
|
|
913
|
-
const finalizers = [];
|
|
914
|
-
let next = this._doneStack.pop();
|
|
915
|
-
while (next) {
|
|
916
|
-
if (next._tag === "ContinuationFinalizer") {
|
|
917
|
-
finalizers.push(next.finalizer);
|
|
918
|
-
}
|
|
919
|
-
next = this._doneStack.pop();
|
|
920
|
-
}
|
|
921
|
-
const effect = finalizers.length === 0 ? unit$1 : runFinalizers(finalizers, exit);
|
|
922
|
-
this.storeInProgressFinalizer(effect);
|
|
923
|
-
return effect;
|
|
924
|
-
}
|
|
925
|
-
popNextFinalizers() {
|
|
926
|
-
const builder = [];
|
|
927
|
-
while (this._doneStack.length !== 0) {
|
|
928
|
-
const cont = this._doneStack[this._doneStack.length - 1];
|
|
929
|
-
if (cont._tag === OP_CONTINUATION_K) {
|
|
930
|
-
return builder;
|
|
931
|
-
}
|
|
932
|
-
builder.push(cont);
|
|
933
|
-
this._doneStack.pop();
|
|
934
|
-
}
|
|
935
|
-
return builder;
|
|
936
|
-
}
|
|
937
|
-
restorePipe(exit, prev) {
|
|
938
|
-
const currInput = this._input;
|
|
939
|
-
this._input = prev;
|
|
940
|
-
if (currInput !== undefined) {
|
|
941
|
-
const effect = currInput.close(exit);
|
|
942
|
-
return effect;
|
|
943
|
-
}
|
|
944
|
-
return unit$1;
|
|
945
|
-
}
|
|
946
|
-
close(exit$1) {
|
|
947
|
-
let runInProgressFinalizers = undefined;
|
|
948
|
-
const finalizer = this._inProgressFinalizer;
|
|
949
|
-
if (finalizer !== undefined) {
|
|
950
|
-
runInProgressFinalizers = pipe(finalizer, ensuring$2(sync$2(() => this.clearInProgressFinalizer())));
|
|
951
|
-
}
|
|
952
|
-
let closeSelf = undefined;
|
|
953
|
-
const selfFinalizers = this.popAllFinalizers(exit$1);
|
|
954
|
-
if (selfFinalizers !== undefined) {
|
|
955
|
-
closeSelf = pipe(selfFinalizers, ensuring$2(sync$2(() => this.clearInProgressFinalizer())));
|
|
956
|
-
}
|
|
957
|
-
const closeSubexecutors = this._activeSubexecutor === undefined ? undefined : this._activeSubexecutor.close(exit$1);
|
|
958
|
-
if (closeSubexecutors === undefined && runInProgressFinalizers === undefined && closeSelf === undefined) {
|
|
959
|
-
return undefined;
|
|
960
|
-
}
|
|
961
|
-
return pipe(exit(ifNotNull(closeSubexecutors)), zip$2(exit(ifNotNull(runInProgressFinalizers))), zip$2(exit(ifNotNull(closeSelf))), map$2(([[exit1, exit2], exit3]) => pipe(exit1, zipRight$2(exit2), zipRight$2(exit3))), uninterruptible,
|
|
962
|
-
// TODO: remove
|
|
963
|
-
flatMap$2(exit => suspend$2(() => exit)));
|
|
964
|
-
}
|
|
965
|
-
doneSucceed(value) {
|
|
966
|
-
if (this._doneStack.length === 0) {
|
|
967
|
-
this._done = succeed$2(value);
|
|
968
|
-
this._currentChannel = undefined;
|
|
969
|
-
return Done();
|
|
970
|
-
}
|
|
971
|
-
const head = this._doneStack[this._doneStack.length - 1];
|
|
972
|
-
if (head._tag === OP_CONTINUATION_K) {
|
|
973
|
-
this._doneStack.pop();
|
|
974
|
-
this._currentChannel = head.onSuccess(value);
|
|
975
|
-
return undefined;
|
|
976
|
-
}
|
|
977
|
-
const finalizers = this.popNextFinalizers();
|
|
978
|
-
if (this._doneStack.length === 0) {
|
|
979
|
-
this._doneStack = finalizers.reverse();
|
|
980
|
-
this._done = succeed$2(value);
|
|
981
|
-
this._currentChannel = undefined;
|
|
982
|
-
return Done();
|
|
983
|
-
}
|
|
984
|
-
const finalizerEffect = runFinalizers(finalizers.map(f => f.finalizer), succeed$2(value));
|
|
985
|
-
this.storeInProgressFinalizer(finalizerEffect);
|
|
986
|
-
const effect = pipe(finalizerEffect, ensuring$2(sync$2(() => this.clearInProgressFinalizer())), uninterruptible, flatMap$2(() => sync$2(() => this.doneSucceed(value))));
|
|
987
|
-
return FromEffect(effect);
|
|
988
|
-
}
|
|
989
|
-
doneHalt(cause) {
|
|
990
|
-
if (this._doneStack.length === 0) {
|
|
991
|
-
this._done = failCause$2(cause);
|
|
992
|
-
this._currentChannel = undefined;
|
|
993
|
-
return Done();
|
|
994
|
-
}
|
|
995
|
-
const head = this._doneStack[this._doneStack.length - 1];
|
|
996
|
-
if (head._tag === OP_CONTINUATION_K) {
|
|
997
|
-
this._doneStack.pop();
|
|
998
|
-
this._currentChannel = head.onHalt(cause);
|
|
999
|
-
return undefined;
|
|
1000
|
-
}
|
|
1001
|
-
const finalizers = this.popNextFinalizers();
|
|
1002
|
-
if (this._doneStack.length === 0) {
|
|
1003
|
-
this._doneStack = finalizers.reverse();
|
|
1004
|
-
this._done = failCause$2(cause);
|
|
1005
|
-
this._currentChannel = undefined;
|
|
1006
|
-
return Done();
|
|
1007
|
-
}
|
|
1008
|
-
const finalizerEffect = runFinalizers(finalizers.map(f => f.finalizer), failCause$2(cause));
|
|
1009
|
-
this.storeInProgressFinalizer(finalizerEffect);
|
|
1010
|
-
const effect = pipe(finalizerEffect, ensuring$2(sync$2(() => this.clearInProgressFinalizer())), uninterruptible, flatMap$2(() => sync$2(() => this.doneHalt(cause))));
|
|
1011
|
-
return FromEffect(effect);
|
|
1012
|
-
}
|
|
1013
|
-
processCancellation() {
|
|
1014
|
-
this._currentChannel = undefined;
|
|
1015
|
-
this._done = this._cancelled;
|
|
1016
|
-
this._cancelled = undefined;
|
|
1017
|
-
return Done();
|
|
1018
|
-
}
|
|
1019
|
-
runBracketOut(bracketOut) {
|
|
1020
|
-
const effect = uninterruptible(matchCauseEffect(this.provide(bracketOut.acquire()), {
|
|
1021
|
-
onFailure: cause => sync$2(() => {
|
|
1022
|
-
this._currentChannel = failCause$1(cause);
|
|
1023
|
-
}),
|
|
1024
|
-
onSuccess: out => sync$2(() => {
|
|
1025
|
-
this.addFinalizer(exit => this.provide(bracketOut.finalizer(out, exit)));
|
|
1026
|
-
this._currentChannel = write(out);
|
|
1027
|
-
})
|
|
1028
|
-
}));
|
|
1029
|
-
return FromEffect(effect);
|
|
1030
|
-
}
|
|
1031
|
-
provide(effect) {
|
|
1032
|
-
if (this._providedEnv === undefined) {
|
|
1033
|
-
return effect;
|
|
1034
|
-
}
|
|
1035
|
-
return pipe(effect, provide(this._providedEnv));
|
|
1036
|
-
}
|
|
1037
|
-
runEnsuring(ensuring) {
|
|
1038
|
-
this.addFinalizer(ensuring.finalizer);
|
|
1039
|
-
this._currentChannel = ensuring.channel;
|
|
1040
|
-
}
|
|
1041
|
-
addFinalizer(f) {
|
|
1042
|
-
this._doneStack.push(new ContinuationFinalizerImpl(f));
|
|
1043
|
-
}
|
|
1044
|
-
runSubexecutor() {
|
|
1045
|
-
const subexecutor = this._activeSubexecutor;
|
|
1046
|
-
switch (subexecutor._tag) {
|
|
1047
|
-
case OP_PULL_FROM_CHILD:
|
|
1048
|
-
{
|
|
1049
|
-
return this.pullFromChild(subexecutor.childExecutor, subexecutor.parentSubexecutor, subexecutor.onEmit, subexecutor);
|
|
1050
|
-
}
|
|
1051
|
-
case OP_PULL_FROM_UPSTREAM:
|
|
1052
|
-
{
|
|
1053
|
-
return this.pullFromUpstream(subexecutor);
|
|
1054
|
-
}
|
|
1055
|
-
case OP_DRAIN_CHILD_EXECUTORS:
|
|
1056
|
-
{
|
|
1057
|
-
return this.drainChildExecutors(subexecutor);
|
|
1058
|
-
}
|
|
1059
|
-
case OP_EMIT:
|
|
1060
|
-
{
|
|
1061
|
-
this._emitted = subexecutor.value;
|
|
1062
|
-
this._activeSubexecutor = subexecutor.next;
|
|
1063
|
-
return Emit$1();
|
|
1064
|
-
}
|
|
1065
|
-
}
|
|
1066
|
-
}
|
|
1067
|
-
replaceSubexecutor(nextSubExec) {
|
|
1068
|
-
this._currentChannel = undefined;
|
|
1069
|
-
this._activeSubexecutor = nextSubExec;
|
|
1070
|
-
}
|
|
1071
|
-
finishWithExit(exit) {
|
|
1072
|
-
const state = match$1(exit, {
|
|
1073
|
-
onFailure: cause => this.doneHalt(cause),
|
|
1074
|
-
onSuccess: value => this.doneSucceed(value)
|
|
1075
|
-
});
|
|
1076
|
-
this._activeSubexecutor = undefined;
|
|
1077
|
-
return state === undefined ? unit$1 : effect(state);
|
|
1078
|
-
}
|
|
1079
|
-
finishSubexecutorWithCloseEffect(subexecutorDone, ...closeFuncs) {
|
|
1080
|
-
this.addFinalizer(() => pipe(closeFuncs, forEach$1(closeFunc => pipe(sync$2(() => closeFunc(subexecutorDone)), flatMap$2(closeEffect => closeEffect !== undefined ? closeEffect : unit$1)), {
|
|
1081
|
-
discard: true
|
|
1082
|
-
})));
|
|
1083
|
-
const state = pipe(subexecutorDone, match$1({
|
|
1084
|
-
onFailure: cause => this.doneHalt(cause),
|
|
1085
|
-
onSuccess: value => this.doneSucceed(value)
|
|
1086
|
-
}));
|
|
1087
|
-
this._activeSubexecutor = undefined;
|
|
1088
|
-
return state;
|
|
1089
|
-
}
|
|
1090
|
-
applyUpstreamPullStrategy(upstreamFinished, queue, strategy) {
|
|
1091
|
-
switch (strategy._tag) {
|
|
1092
|
-
case OP_PULL_AFTER_NEXT:
|
|
1093
|
-
{
|
|
1094
|
-
const shouldPrepend = !upstreamFinished || queue.some(subexecutor => subexecutor !== undefined);
|
|
1095
|
-
return [strategy.emitSeparator, shouldPrepend ? [undefined, ...queue] : queue];
|
|
1096
|
-
}
|
|
1097
|
-
case OP_PULL_AFTER_ALL_ENQUEUED:
|
|
1098
|
-
{
|
|
1099
|
-
const shouldEnqueue = !upstreamFinished || queue.some(subexecutor => subexecutor !== undefined);
|
|
1100
|
-
return [strategy.emitSeparator, shouldEnqueue ? [...queue, undefined] : queue];
|
|
1101
|
-
}
|
|
1102
|
-
}
|
|
1103
|
-
}
|
|
1104
|
-
pullFromChild(childExecutor, parentSubexecutor, onEmitted, subexecutor) {
|
|
1105
|
-
return Read(childExecutor, identity, emitted => {
|
|
1106
|
-
const childExecutorDecision = onEmitted(emitted);
|
|
1107
|
-
switch (childExecutorDecision._tag) {
|
|
1108
|
-
case OP_CONTINUE:
|
|
1109
|
-
{
|
|
1110
|
-
break;
|
|
1111
|
-
}
|
|
1112
|
-
case OP_CLOSE:
|
|
1113
|
-
{
|
|
1114
|
-
this.finishWithDoneValue(childExecutor, parentSubexecutor, childExecutorDecision.value);
|
|
1115
|
-
break;
|
|
1116
|
-
}
|
|
1117
|
-
case OP_YIELD:
|
|
1118
|
-
{
|
|
1119
|
-
const modifiedParent = parentSubexecutor.enqueuePullFromChild(subexecutor);
|
|
1120
|
-
this.replaceSubexecutor(modifiedParent);
|
|
1121
|
-
break;
|
|
1122
|
-
}
|
|
1123
|
-
}
|
|
1124
|
-
this._activeSubexecutor = new Emit(emitted, this._activeSubexecutor);
|
|
1125
|
-
return undefined;
|
|
1126
|
-
}, match$1({
|
|
1127
|
-
onFailure: cause => {
|
|
1128
|
-
const state = this.handleSubexecutorFailure(childExecutor, parentSubexecutor, cause);
|
|
1129
|
-
return state === undefined ? undefined : effectOrUndefinedIgnored(state);
|
|
1130
|
-
},
|
|
1131
|
-
onSuccess: doneValue => {
|
|
1132
|
-
this.finishWithDoneValue(childExecutor, parentSubexecutor, doneValue);
|
|
1133
|
-
return undefined;
|
|
1134
|
-
}
|
|
1135
|
-
}));
|
|
1136
|
-
}
|
|
1137
|
-
finishWithDoneValue(childExecutor, parentSubexecutor, doneValue) {
|
|
1138
|
-
const subexecutor = parentSubexecutor;
|
|
1139
|
-
switch (subexecutor._tag) {
|
|
1140
|
-
case OP_PULL_FROM_UPSTREAM:
|
|
1141
|
-
{
|
|
1142
|
-
const modifiedParent = new PullFromUpstream(subexecutor.upstreamExecutor, subexecutor.createChild, subexecutor.lastDone !== undefined ? subexecutor.combineChildResults(subexecutor.lastDone, doneValue) : doneValue, subexecutor.activeChildExecutors, subexecutor.combineChildResults, subexecutor.combineWithChildResult, subexecutor.onPull, subexecutor.onEmit);
|
|
1143
|
-
this._closeLastSubstream = childExecutor.close(succeed$2(doneValue));
|
|
1144
|
-
this.replaceSubexecutor(modifiedParent);
|
|
1145
|
-
break;
|
|
1146
|
-
}
|
|
1147
|
-
case OP_DRAIN_CHILD_EXECUTORS:
|
|
1148
|
-
{
|
|
1149
|
-
const modifiedParent = new DrainChildExecutors(subexecutor.upstreamExecutor, subexecutor.lastDone !== undefined ? subexecutor.combineChildResults(subexecutor.lastDone, doneValue) : doneValue, subexecutor.activeChildExecutors, subexecutor.upstreamDone, subexecutor.combineChildResults, subexecutor.combineWithChildResult, subexecutor.onPull);
|
|
1150
|
-
this._closeLastSubstream = childExecutor.close(succeed$2(doneValue));
|
|
1151
|
-
this.replaceSubexecutor(modifiedParent);
|
|
1152
|
-
break;
|
|
1153
|
-
}
|
|
1154
|
-
}
|
|
1155
|
-
}
|
|
1156
|
-
handleSubexecutorFailure(childExecutor, parentSubexecutor, cause) {
|
|
1157
|
-
return this.finishSubexecutorWithCloseEffect(failCause$2(cause), exit => parentSubexecutor.close(exit), exit => childExecutor.close(exit));
|
|
1158
|
-
}
|
|
1159
|
-
pullFromUpstream(subexecutor) {
|
|
1160
|
-
if (subexecutor.activeChildExecutors.length === 0) {
|
|
1161
|
-
return this.performPullFromUpstream(subexecutor);
|
|
1162
|
-
}
|
|
1163
|
-
const activeChild = subexecutor.activeChildExecutors[0];
|
|
1164
|
-
const parentSubexecutor = new PullFromUpstream(subexecutor.upstreamExecutor, subexecutor.createChild, subexecutor.lastDone, subexecutor.activeChildExecutors.slice(1), subexecutor.combineChildResults, subexecutor.combineWithChildResult, subexecutor.onPull, subexecutor.onEmit);
|
|
1165
|
-
if (activeChild === undefined) {
|
|
1166
|
-
return this.performPullFromUpstream(parentSubexecutor);
|
|
1167
|
-
}
|
|
1168
|
-
this.replaceSubexecutor(new PullFromChild(activeChild.childExecutor, parentSubexecutor, activeChild.onEmit));
|
|
1169
|
-
return undefined;
|
|
1170
|
-
}
|
|
1171
|
-
performPullFromUpstream(subexecutor) {
|
|
1172
|
-
return Read(subexecutor.upstreamExecutor, effect => {
|
|
1173
|
-
const closeLastSubstream = this._closeLastSubstream === undefined ? unit$1 : this._closeLastSubstream;
|
|
1174
|
-
this._closeLastSubstream = undefined;
|
|
1175
|
-
return pipe(this._executeCloseLastSubstream(closeLastSubstream), zipRight$3(effect));
|
|
1176
|
-
}, emitted => {
|
|
1177
|
-
if (this._closeLastSubstream !== undefined) {
|
|
1178
|
-
const closeLastSubstream = this._closeLastSubstream;
|
|
1179
|
-
this._closeLastSubstream = undefined;
|
|
1180
|
-
return pipe(this._executeCloseLastSubstream(closeLastSubstream), map$2(() => {
|
|
1181
|
-
const childExecutor = new ChannelExecutor(subexecutor.createChild(emitted), this._providedEnv, this._executeCloseLastSubstream);
|
|
1182
|
-
childExecutor._input = this._input;
|
|
1183
|
-
const [emitSeparator, updatedChildExecutors] = this.applyUpstreamPullStrategy(false, subexecutor.activeChildExecutors, subexecutor.onPull(Pulled(emitted)));
|
|
1184
|
-
this._activeSubexecutor = new PullFromChild(childExecutor, new PullFromUpstream(subexecutor.upstreamExecutor, subexecutor.createChild, subexecutor.lastDone, updatedChildExecutors, subexecutor.combineChildResults, subexecutor.combineWithChildResult, subexecutor.onPull, subexecutor.onEmit), subexecutor.onEmit);
|
|
1185
|
-
if (isSome(emitSeparator)) {
|
|
1186
|
-
this._activeSubexecutor = new Emit(emitSeparator.value, this._activeSubexecutor);
|
|
1187
|
-
}
|
|
1188
|
-
return undefined;
|
|
1189
|
-
}));
|
|
1190
|
-
}
|
|
1191
|
-
const childExecutor = new ChannelExecutor(subexecutor.createChild(emitted), this._providedEnv, this._executeCloseLastSubstream);
|
|
1192
|
-
childExecutor._input = this._input;
|
|
1193
|
-
const [emitSeparator, updatedChildExecutors] = this.applyUpstreamPullStrategy(false, subexecutor.activeChildExecutors, subexecutor.onPull(Pulled(emitted)));
|
|
1194
|
-
this._activeSubexecutor = new PullFromChild(childExecutor, new PullFromUpstream(subexecutor.upstreamExecutor, subexecutor.createChild, subexecutor.lastDone, updatedChildExecutors, subexecutor.combineChildResults, subexecutor.combineWithChildResult, subexecutor.onPull, subexecutor.onEmit), subexecutor.onEmit);
|
|
1195
|
-
if (isSome(emitSeparator)) {
|
|
1196
|
-
this._activeSubexecutor = new Emit(emitSeparator.value, this._activeSubexecutor);
|
|
1197
|
-
}
|
|
1198
|
-
return undefined;
|
|
1199
|
-
}, exit => {
|
|
1200
|
-
if (subexecutor.activeChildExecutors.some(subexecutor => subexecutor !== undefined)) {
|
|
1201
|
-
const drain = new DrainChildExecutors(subexecutor.upstreamExecutor, subexecutor.lastDone, [undefined, ...subexecutor.activeChildExecutors], subexecutor.upstreamExecutor.getDone(), subexecutor.combineChildResults, subexecutor.combineWithChildResult, subexecutor.onPull);
|
|
1202
|
-
if (this._closeLastSubstream !== undefined) {
|
|
1203
|
-
const closeLastSubstream = this._closeLastSubstream;
|
|
1204
|
-
this._closeLastSubstream = undefined;
|
|
1205
|
-
return pipe(this._executeCloseLastSubstream(closeLastSubstream), map$2(() => this.replaceSubexecutor(drain)));
|
|
1206
|
-
}
|
|
1207
|
-
this.replaceSubexecutor(drain);
|
|
1208
|
-
return undefined;
|
|
1209
|
-
}
|
|
1210
|
-
const closeLastSubstream = this._closeLastSubstream;
|
|
1211
|
-
const state = this.finishSubexecutorWithCloseEffect(pipe(exit, map$3(a => subexecutor.combineWithChildResult(subexecutor.lastDone, a))), () => closeLastSubstream, exit => subexecutor.upstreamExecutor.close(exit));
|
|
1212
|
-
return state === undefined ? undefined :
|
|
1213
|
-
// NOTE: assuming finalizers cannot fail
|
|
1214
|
-
effectOrUndefinedIgnored(state);
|
|
1215
|
-
});
|
|
1216
|
-
}
|
|
1217
|
-
drainChildExecutors(subexecutor) {
|
|
1218
|
-
if (subexecutor.activeChildExecutors.length === 0) {
|
|
1219
|
-
const lastClose = this._closeLastSubstream;
|
|
1220
|
-
if (lastClose !== undefined) {
|
|
1221
|
-
this.addFinalizer(() => succeed$3(lastClose));
|
|
1222
|
-
}
|
|
1223
|
-
return this.finishSubexecutorWithCloseEffect(subexecutor.upstreamDone, () => lastClose, exit => subexecutor.upstreamExecutor.close(exit));
|
|
1224
|
-
}
|
|
1225
|
-
const activeChild = subexecutor.activeChildExecutors[0];
|
|
1226
|
-
const rest = subexecutor.activeChildExecutors.slice(1);
|
|
1227
|
-
if (activeChild === undefined) {
|
|
1228
|
-
const [emitSeparator, remainingExecutors] = this.applyUpstreamPullStrategy(true, rest, subexecutor.onPull(NoUpstream(rest.reduce((n, curr) => curr !== undefined ? n + 1 : n, 0))));
|
|
1229
|
-
this.replaceSubexecutor(new DrainChildExecutors(subexecutor.upstreamExecutor, subexecutor.lastDone, remainingExecutors, subexecutor.upstreamDone, subexecutor.combineChildResults, subexecutor.combineWithChildResult, subexecutor.onPull));
|
|
1230
|
-
if (isSome(emitSeparator)) {
|
|
1231
|
-
this._emitted = emitSeparator.value;
|
|
1232
|
-
return Emit$1();
|
|
1233
|
-
}
|
|
1234
|
-
return undefined;
|
|
1235
|
-
}
|
|
1236
|
-
const parentSubexecutor = new DrainChildExecutors(subexecutor.upstreamExecutor, subexecutor.lastDone, rest, subexecutor.upstreamDone, subexecutor.combineChildResults, subexecutor.combineWithChildResult, subexecutor.onPull);
|
|
1237
|
-
this.replaceSubexecutor(new PullFromChild(activeChild.childExecutor, parentSubexecutor, activeChild.onEmit));
|
|
1238
|
-
return undefined;
|
|
1239
|
-
}
|
|
1240
|
-
}
|
|
1241
|
-
const ifNotNull = effect => effect !== undefined ? effect : unit$1;
|
|
1242
|
-
const runFinalizers = (finalizers, exit$1) => {
|
|
1243
|
-
return pipe(forEach$1(finalizers, fin => exit(fin(exit$1))), map$2(exits => pipe(all(exits), getOrElse(() => unit$2))), flatMap$2(exit => suspend$2(() => exit)));
|
|
1244
|
-
};
|
|
1245
|
-
|
|
1246
|
-
/**
|
|
1247
|
-
* @internal
|
|
1248
|
-
*/
|
|
1249
|
-
const readUpstream = (r, onSuccess, onFailure) => {
|
|
1250
|
-
const readStack = [r];
|
|
1251
|
-
const read = () => {
|
|
1252
|
-
const current = readStack.pop();
|
|
1253
|
-
if (current === undefined || current.upstream === undefined) {
|
|
1254
|
-
return dieMessage$1("Unexpected end of input for channel execution");
|
|
1255
|
-
}
|
|
1256
|
-
const state = current.upstream.run();
|
|
1257
|
-
switch (state._tag) {
|
|
1258
|
-
case OP_EMIT$1:
|
|
1259
|
-
{
|
|
1260
|
-
const emitEffect = current.onEmit(current.upstream.getEmit());
|
|
1261
|
-
if (readStack.length === 0) {
|
|
1262
|
-
if (emitEffect === undefined) {
|
|
1263
|
-
return suspend$2(onSuccess);
|
|
1264
|
-
}
|
|
1265
|
-
return pipe(emitEffect, matchCauseEffect({
|
|
1266
|
-
onFailure,
|
|
1267
|
-
onSuccess
|
|
1268
|
-
}));
|
|
1269
|
-
}
|
|
1270
|
-
if (emitEffect === undefined) {
|
|
1271
|
-
return suspend$2(() => read());
|
|
1272
|
-
}
|
|
1273
|
-
return pipe(emitEffect, matchCauseEffect({
|
|
1274
|
-
onFailure,
|
|
1275
|
-
onSuccess: () => read()
|
|
1276
|
-
}));
|
|
1277
|
-
}
|
|
1278
|
-
case OP_DONE:
|
|
1279
|
-
{
|
|
1280
|
-
const doneEffect = current.onDone(current.upstream.getDone());
|
|
1281
|
-
if (readStack.length === 0) {
|
|
1282
|
-
if (doneEffect === undefined) {
|
|
1283
|
-
return suspend$2(onSuccess);
|
|
1284
|
-
}
|
|
1285
|
-
return pipe(doneEffect, matchCauseEffect({
|
|
1286
|
-
onFailure,
|
|
1287
|
-
onSuccess
|
|
1288
|
-
}));
|
|
1289
|
-
}
|
|
1290
|
-
if (doneEffect === undefined) {
|
|
1291
|
-
return suspend$2(() => read());
|
|
1292
|
-
}
|
|
1293
|
-
return pipe(doneEffect, matchCauseEffect({
|
|
1294
|
-
onFailure,
|
|
1295
|
-
onSuccess: () => read()
|
|
1296
|
-
}));
|
|
1297
|
-
}
|
|
1298
|
-
case OP_FROM_EFFECT:
|
|
1299
|
-
{
|
|
1300
|
-
readStack.push(current);
|
|
1301
|
-
return pipe(current.onEffect(state.effect), catchAllCause$1(cause => suspend$2(() => {
|
|
1302
|
-
const doneEffect = current.onDone(failCause$2(cause));
|
|
1303
|
-
return doneEffect === undefined ? unit$1 : doneEffect;
|
|
1304
|
-
})), matchCauseEffect({
|
|
1305
|
-
onFailure,
|
|
1306
|
-
onSuccess: () => read()
|
|
1307
|
-
}));
|
|
1308
|
-
}
|
|
1309
|
-
case OP_READ:
|
|
1310
|
-
{
|
|
1311
|
-
readStack.push(current);
|
|
1312
|
-
readStack.push(state);
|
|
1313
|
-
return suspend$2(() => read());
|
|
1314
|
-
}
|
|
1315
|
-
}
|
|
1316
|
-
};
|
|
1317
|
-
return read();
|
|
1318
|
-
};
|
|
1319
|
-
|
|
1320
|
-
/** @internal */
|
|
1321
|
-
const run$1 = self => pipe(runScoped(self), scoped$1);
|
|
1322
|
-
|
|
1323
|
-
/** @internal */
|
|
1324
|
-
const runScoped = self => {
|
|
1325
|
-
const run = (channelDeferred, scopeDeferred, scope) => acquireUseRelease$1(sync$2(() => new ChannelExecutor(self, void 0, identity)), exec => suspend$2(() => pipe(runScopedInterpret(exec.run(), exec), intoDeferred(channelDeferred), zipRight$3(_await(channelDeferred)), zipLeft$2(_await(scopeDeferred)))), (exec, exit) => {
|
|
1326
|
-
const finalize = exec.close(exit);
|
|
1327
|
-
if (finalize === undefined) {
|
|
1328
|
-
return unit$1;
|
|
1329
|
-
}
|
|
1330
|
-
return tapErrorCause(finalize, cause => addFinalizer$1(scope, failCause$3(cause)));
|
|
1331
|
-
});
|
|
1332
|
-
return uninterruptibleMask(restore => flatMap$2(scope, parent => pipe(all$1([fork(parent, sequential), make(), make()]), flatMap$2(([child, channelDeferred, scopeDeferred]) => pipe(forkScoped(restore(run(channelDeferred, scopeDeferred, child))), flatMap$2(fiber => pipe(addFinalizer(() => succeed$4(scopeDeferred, void 0)), zipRight$3(restore(_await(channelDeferred))), zipLeft$2(inheritAll(fiber)))))))));
|
|
1333
|
-
};
|
|
1334
|
-
|
|
1335
|
-
/** @internal */
|
|
1336
|
-
const runScopedInterpret = (channelState, exec) => {
|
|
1337
|
-
const op = channelState;
|
|
1338
|
-
switch (op._tag) {
|
|
1339
|
-
case OP_FROM_EFFECT:
|
|
1340
|
-
{
|
|
1341
|
-
return pipe(op.effect, flatMap$2(() => runScopedInterpret(exec.run(), exec)));
|
|
1342
|
-
}
|
|
1343
|
-
case OP_EMIT$1:
|
|
1344
|
-
{
|
|
1345
|
-
// Can't really happen because Out <:< Nothing. So just skip ahead.
|
|
1346
|
-
return runScopedInterpret(exec.run(), exec);
|
|
1347
|
-
}
|
|
1348
|
-
case OP_DONE:
|
|
1349
|
-
{
|
|
1350
|
-
return suspend$2(() => exec.getDone());
|
|
1351
|
-
}
|
|
1352
|
-
case OP_READ:
|
|
1353
|
-
{
|
|
1354
|
-
return readUpstream(op, () => runScopedInterpret(exec.run(), exec), failCause$3);
|
|
1355
|
-
}
|
|
1356
|
-
}
|
|
1357
|
-
};
|
|
1358
|
-
|
|
1359
|
-
/** @internal */
|
|
1360
|
-
const acquireUseRelease = (acquire, use, release) => flatMap$1(fromEffect$1(make$1(() => unit$1)), ref => pipe(fromEffect$1(uninterruptible(tap(acquire, a => set(ref, exit => release(a, exit))))), flatMap$1(use), ensuringWith$1(exit => flatMap$2(get(ref), f => f(exit)))));
|
|
1361
|
-
|
|
1362
|
-
/** @internal */
|
|
1363
|
-
const as$1 = /*#__PURE__*/dual(2, (self, value) => map$1(self, () => value));
|
|
1364
|
-
|
|
1365
|
-
/** @internal */
|
|
1366
|
-
const asUnit = self => map$1(self, constVoid);
|
|
1367
|
-
|
|
1368
|
-
/** @internal */
|
|
1369
|
-
const buffer = options => suspend$1(() => {
|
|
1370
|
-
const doBuffer = (empty, isEmpty, ref) => unwrap$1(modify(ref, inElem => isEmpty(inElem) ? [readWith({
|
|
1371
|
-
onInput: input => flatMap$1(write(input), () => doBuffer(empty, isEmpty, ref)),
|
|
1372
|
-
onFailure: error => fail$1(error),
|
|
1373
|
-
onDone: done => succeedNow(done)
|
|
1374
|
-
}), inElem] : [flatMap$1(write(inElem), () => doBuffer(empty, isEmpty, ref)), empty]));
|
|
1375
|
-
return doBuffer(options.empty, options.isEmpty, options.ref);
|
|
1376
|
-
});
|
|
1377
|
-
|
|
1378
|
-
/** @internal */
|
|
1379
|
-
const bufferChunk = ref => buffer({
|
|
1380
|
-
empty: empty(),
|
|
1381
|
-
isEmpty: isEmpty,
|
|
1382
|
-
ref
|
|
1383
|
-
});
|
|
1384
|
-
|
|
1385
|
-
/** @internal */
|
|
1386
|
-
const catchAll = /*#__PURE__*/dual(2, (self, f) => catchAllCause(self, cause => match(failureOrCause(cause), {
|
|
1387
|
-
onLeft: f,
|
|
1388
|
-
onRight: failCause$1
|
|
1389
|
-
})));
|
|
1390
|
-
|
|
1391
|
-
/** @internal */
|
|
1392
|
-
const concatMap = /*#__PURE__*/dual(2, (self, f) => concatMapWith(self, f, () => void 0, () => void 0));
|
|
1393
|
-
|
|
1394
|
-
/** @internal */
|
|
1395
|
-
const collect = /*#__PURE__*/dual(2, (self, pf) => {
|
|
1396
|
-
const collector = readWith({
|
|
1397
|
-
onInput: out => match$2(pf(out), {
|
|
1398
|
-
onNone: () => collector,
|
|
1399
|
-
onSome: out2 => flatMap$1(write(out2), () => collector)
|
|
1400
|
-
}),
|
|
1401
|
-
onFailure: fail$1,
|
|
1402
|
-
onDone: succeedNow
|
|
1403
|
-
});
|
|
1404
|
-
return pipeTo(self, collector);
|
|
1405
|
-
});
|
|
1406
|
-
|
|
1407
|
-
/** @internal */
|
|
1408
|
-
const concatOut = self => concatAll(self);
|
|
1409
|
-
|
|
1410
|
-
/** @internal */
|
|
1411
|
-
const mapInput$1 = /*#__PURE__*/dual(2, (self, f) => {
|
|
1412
|
-
const reader = readWith({
|
|
1413
|
-
onInput: inElem => flatMap$1(write(inElem), () => reader),
|
|
1414
|
-
onFailure: fail$1,
|
|
1415
|
-
onDone: done => succeedNow(f(done))
|
|
1416
|
-
});
|
|
1417
|
-
return pipeTo(reader, self);
|
|
1418
|
-
});
|
|
1419
|
-
|
|
1420
|
-
/** @internal */
|
|
1421
|
-
const mapInputEffect$1 = /*#__PURE__*/dual(2, (self, f) => {
|
|
1422
|
-
const reader = readWith({
|
|
1423
|
-
onInput: inElem => flatMap$1(write(inElem), () => reader),
|
|
1424
|
-
onFailure: fail$1,
|
|
1425
|
-
onDone: done => fromEffect$1(f(done))
|
|
1426
|
-
});
|
|
1427
|
-
return pipeTo(reader, self);
|
|
1428
|
-
});
|
|
1429
|
-
|
|
1430
|
-
/** @internal */
|
|
1431
|
-
const mapInputError = /*#__PURE__*/dual(2, (self, f) => {
|
|
1432
|
-
const reader = readWith({
|
|
1433
|
-
onInput: inElem => flatMap$1(write(inElem), () => reader),
|
|
1434
|
-
onFailure: error => fail$1(f(error)),
|
|
1435
|
-
onDone: succeedNow
|
|
1436
|
-
});
|
|
1437
|
-
return pipeTo(reader, self);
|
|
1438
|
-
});
|
|
1439
|
-
|
|
1440
|
-
/** @internal */
|
|
1441
|
-
const mapInputErrorEffect = /*#__PURE__*/dual(2, (self, f) => {
|
|
1442
|
-
const reader = readWith({
|
|
1443
|
-
onInput: inElem => flatMap$1(write(inElem), () => reader),
|
|
1444
|
-
onFailure: error => fromEffect$1(f(error)),
|
|
1445
|
-
onDone: succeedNow
|
|
1446
|
-
});
|
|
1447
|
-
return pipeTo(reader, self);
|
|
1448
|
-
});
|
|
1449
|
-
|
|
1450
|
-
/** @internal */
|
|
1451
|
-
const mapInputIn = /*#__PURE__*/dual(2, (self, f) => {
|
|
1452
|
-
const reader = readWith({
|
|
1453
|
-
onInput: inElem => flatMap$1(write(f(inElem)), () => reader),
|
|
1454
|
-
onFailure: fail$1,
|
|
1455
|
-
onDone: succeedNow
|
|
1456
|
-
});
|
|
1457
|
-
return pipeTo(reader, self);
|
|
1458
|
-
});
|
|
1459
|
-
const mapInputInEffect = /*#__PURE__*/dual(2, (self, f) => {
|
|
1460
|
-
const reader = readWith({
|
|
1461
|
-
onInput: inElem => flatMap$1(flatMap$1(fromEffect$1(f(inElem)), write), () => reader),
|
|
1462
|
-
onFailure: fail$1,
|
|
1463
|
-
onDone: succeedNow
|
|
1464
|
-
});
|
|
1465
|
-
return pipeTo(reader, self);
|
|
1466
|
-
});
|
|
1467
|
-
|
|
1468
|
-
/** @internal */
|
|
1469
|
-
const doneCollect = self => suspend$1(() => {
|
|
1470
|
-
const builder = [];
|
|
1471
|
-
return pipe(pipeTo(self, doneCollectReader(builder)), flatMap$1(outDone => succeed$1([unsafeFromArray(builder), outDone])));
|
|
1472
|
-
});
|
|
1473
|
-
|
|
1474
|
-
/** @internal */
|
|
1475
|
-
const doneCollectReader = builder => {
|
|
1476
|
-
return readWith({
|
|
1477
|
-
onInput: outElem => flatMap$1(sync$1(() => {
|
|
1478
|
-
builder.push(outElem);
|
|
1479
|
-
}), () => doneCollectReader(builder)),
|
|
1480
|
-
onFailure: fail$1,
|
|
1481
|
-
onDone: succeed$1
|
|
1482
|
-
});
|
|
1483
|
-
};
|
|
1484
|
-
|
|
1485
|
-
/** @internal */
|
|
1486
|
-
const drain$1 = self => {
|
|
1487
|
-
const drainer = readWithCause({
|
|
1488
|
-
onInput: () => drainer,
|
|
1489
|
-
onFailure: failCause$1,
|
|
1490
|
-
onDone: succeed$1
|
|
1491
|
-
});
|
|
1492
|
-
return pipeTo(self, drainer);
|
|
1493
|
-
};
|
|
1494
|
-
|
|
1495
|
-
/** @internal */
|
|
1496
|
-
const emitCollect = self => flatMap$1(doneCollect(self), write);
|
|
1497
|
-
|
|
1498
|
-
/** @internal */
|
|
1499
|
-
const ensuring$1 = /*#__PURE__*/dual(2, (self, finalizer) => ensuringWith$1(self, () => finalizer));
|
|
1500
|
-
|
|
1501
|
-
/** @internal */
|
|
1502
|
-
const context$1 = () => fromEffect$1(context$2());
|
|
1503
|
-
|
|
1504
|
-
/** @internal */
|
|
1505
|
-
const contextWith$1 = f => map$1(context$1(), f);
|
|
1506
|
-
|
|
1507
|
-
/** @internal */
|
|
1508
|
-
const contextWithChannel = f => flatMap$1(context$1(), f);
|
|
1509
|
-
|
|
1510
|
-
/** @internal */
|
|
1511
|
-
const contextWithEffect$1 = f => mapEffect$1(context$1(), f);
|
|
1512
|
-
|
|
1513
|
-
/** @internal */
|
|
1514
|
-
const flatten = self => flatMap$1(self, identity);
|
|
1515
|
-
|
|
1516
|
-
/** @internal */
|
|
1517
|
-
const foldChannel = /*#__PURE__*/dual(2, (self, options) => foldCauseChannel(self, {
|
|
1518
|
-
onFailure: cause => {
|
|
1519
|
-
const either = failureOrCause(cause);
|
|
1520
|
-
switch (either._tag) {
|
|
1521
|
-
case "Left":
|
|
1522
|
-
{
|
|
1523
|
-
return options.onFailure(either.left);
|
|
1524
|
-
}
|
|
1525
|
-
case "Right":
|
|
1526
|
-
{
|
|
1527
|
-
return failCause$1(either.right);
|
|
1528
|
-
}
|
|
1529
|
-
}
|
|
1530
|
-
},
|
|
1531
|
-
onSuccess: options.onSuccess
|
|
1532
|
-
}));
|
|
1533
|
-
|
|
1534
|
-
/** @internal */
|
|
1535
|
-
const fromEither = either => suspend$1(() => match(either, {
|
|
1536
|
-
onLeft: fail$1,
|
|
1537
|
-
onRight: succeed$1
|
|
1538
|
-
}));
|
|
1539
|
-
|
|
1540
|
-
/** @internal */
|
|
1541
|
-
const fromInput = input => unwrap$1(input.takeWith(failCause$1, elem => flatMap$1(write(elem), () => fromInput(input)), succeed$1));
|
|
1542
|
-
|
|
1543
|
-
/** @internal */
|
|
1544
|
-
const fromHub$1 = hub => unwrapScoped$1(map$2(subscribe(hub), fromQueue$1));
|
|
1545
|
-
|
|
1546
|
-
/** @internal */
|
|
1547
|
-
const fromHubScoped = hub => map$2(subscribe(hub), fromQueue$1);
|
|
1548
|
-
|
|
1549
|
-
/** @internal */
|
|
1550
|
-
const fromOption = option => suspend$1(() => match$2(option, {
|
|
1551
|
-
onNone: () => fail$1(none()),
|
|
1552
|
-
onSome: succeed$1
|
|
1553
|
-
}));
|
|
1554
|
-
|
|
1555
|
-
/** @internal */
|
|
1556
|
-
const fromQueue$1 = queue => suspend$1(() => fromQueueInternal(queue));
|
|
1557
|
-
|
|
1558
|
-
/** @internal */
|
|
1559
|
-
const fromQueueInternal = queue => pipe(fromEffect$1(take$1(queue)), flatMap$1(match({
|
|
1560
|
-
onLeft: match$1({
|
|
1561
|
-
onFailure: failCause$1,
|
|
1562
|
-
onSuccess: succeedNow
|
|
1563
|
-
}),
|
|
1564
|
-
onRight: elem => flatMap$1(write(elem), () => fromQueueInternal(queue))
|
|
1565
|
-
})));
|
|
1566
|
-
|
|
1567
|
-
/** @internal */
|
|
1568
|
-
const identityChannel = () => readWith({
|
|
1569
|
-
onInput: input => flatMap$1(write(input), () => identityChannel()),
|
|
1570
|
-
onFailure: fail$1,
|
|
1571
|
-
onDone: succeedNow
|
|
1572
|
-
});
|
|
1573
|
-
|
|
1574
|
-
/** @internal */
|
|
1575
|
-
const interruptWhen = /*#__PURE__*/dual(2, (self, effect) => mergeWith(self, {
|
|
1576
|
-
other: fromEffect$1(effect),
|
|
1577
|
-
onSelfDone: selfDone => Done$1(suspend$2(() => selfDone)),
|
|
1578
|
-
onOtherDone: effectDone => Done$1(suspend$2(() => effectDone))
|
|
1579
|
-
}));
|
|
1580
|
-
|
|
1581
|
-
/** @internal */
|
|
1582
|
-
const interruptWhenDeferred = /*#__PURE__*/dual(2, (self, deferred) => interruptWhen(self, _await(deferred)));
|
|
1583
|
-
|
|
1584
|
-
/** @internal */
|
|
1585
|
-
const map$1 = /*#__PURE__*/dual(2, (self, f) => flatMap$1(self, a => sync$1(() => f(a))));
|
|
1586
|
-
|
|
1587
|
-
/** @internal */
|
|
1588
|
-
const mapEffect$1 = /*#__PURE__*/dual(2, (self, f) => flatMap$1(self, z => fromEffect$1(f(z))));
|
|
1589
|
-
|
|
1590
|
-
/** @internal */
|
|
1591
|
-
const mapError$1 = /*#__PURE__*/dual(2, (self, f) => mapErrorCause(self, map$4(f)));
|
|
1592
|
-
|
|
1593
|
-
/** @internal */
|
|
1594
|
-
const mapErrorCause = /*#__PURE__*/dual(2, (self, f) => catchAllCause(self, cause => failCause$1(f(cause))));
|
|
1595
|
-
|
|
1596
|
-
/** @internal */
|
|
1597
|
-
const mapOut = /*#__PURE__*/dual(2, (self, f) => {
|
|
1598
|
-
const reader = readWith({
|
|
1599
|
-
onInput: outElem => flatMap$1(write(f(outElem)), () => reader),
|
|
1600
|
-
onFailure: fail$1,
|
|
1601
|
-
onDone: succeedNow
|
|
1602
|
-
});
|
|
1603
|
-
return pipeTo(self, reader);
|
|
1604
|
-
});
|
|
1605
|
-
|
|
1606
|
-
/** @internal */
|
|
1607
|
-
const mapOutEffect = /*#__PURE__*/dual(2, (self, f) => {
|
|
1608
|
-
const reader = readWithCause({
|
|
1609
|
-
onInput: outElem => pipe(fromEffect$1(f(outElem)), flatMap$1(write), flatMap$1(() => reader)),
|
|
1610
|
-
onFailure: failCause$1,
|
|
1611
|
-
onDone: succeedNow
|
|
1612
|
-
});
|
|
1613
|
-
return pipeTo(self, reader);
|
|
1614
|
-
});
|
|
1615
|
-
|
|
1616
|
-
/** @internal */
|
|
1617
|
-
const mapOutEffectPar = /*#__PURE__*/dual(3, (self, f, n) => pipe(gen(function* ($) {
|
|
1618
|
-
const queue = yield* $(acquireRelease(bounded(n), queue => shutdown(queue)));
|
|
1619
|
-
const errorSignal = yield* $(make());
|
|
1620
|
-
const withPermits = n === Number.POSITIVE_INFINITY ? _ => identity : (yield* $(makeSemaphore(n))).withPermits;
|
|
1621
|
-
const pull = yield* $(toPull(self));
|
|
1622
|
-
yield* $(matchCauseEffect(pull, {
|
|
1623
|
-
onFailure: cause => offer(queue, failCause$3(cause)),
|
|
1624
|
-
onSuccess: either => match(either, {
|
|
1625
|
-
onLeft: outDone => {
|
|
1626
|
-
const lock = withPermits(n);
|
|
1627
|
-
return zipRight$3(interruptible(lock(unit$1)), asUnit$1(offer(queue, succeed$3(left(outDone)))));
|
|
1628
|
-
},
|
|
1629
|
-
onRight: outElem => gen(function* ($) {
|
|
1630
|
-
const deferred = yield* $(make());
|
|
1631
|
-
const latch = yield* $(make());
|
|
1632
|
-
yield* $(asUnit$1(offer(queue, map$2(_await(deferred), right))));
|
|
1633
|
-
yield* $(succeed$4(latch, void 0), zipRight$3(pipe(uninterruptibleMask(restore => pipe(exit(restore(_await(errorSignal))), raceFirst(exit(restore(f(outElem)))),
|
|
1634
|
-
// TODO: remove
|
|
1635
|
-
flatMap$2(exit => suspend$2(() => exit)))), tapErrorCause(cause => failCause$4(errorSignal, cause)), intoDeferred(deferred))), withPermits(1), forkScoped);
|
|
1636
|
-
yield* $(_await(latch));
|
|
1637
|
-
})
|
|
1638
|
-
})
|
|
1639
|
-
}), forever, interruptible, forkScoped);
|
|
1640
|
-
return queue;
|
|
1641
|
-
}), map$2(queue => {
|
|
1642
|
-
const consumer = unwrap$1(matchCause(flatten$1(take$1(queue)), {
|
|
1643
|
-
onFailure: failCause$1,
|
|
1644
|
-
onSuccess: match({
|
|
1645
|
-
onLeft: succeedNow,
|
|
1646
|
-
onRight: outElem => flatMap$1(write(outElem), () => consumer)
|
|
1647
|
-
})
|
|
1648
|
-
}));
|
|
1649
|
-
return consumer;
|
|
1650
|
-
}), unwrapScoped$1));
|
|
1651
|
-
|
|
1652
|
-
/** @internal */
|
|
1653
|
-
const mergeAll = options => {
|
|
1654
|
-
return channels => mergeAllWith(options)(channels, constVoid);
|
|
1655
|
-
};
|
|
1656
|
-
|
|
1657
|
-
/** @internal */
|
|
1658
|
-
const mergeAllUnbounded = channels => mergeAllWith({
|
|
1659
|
-
concurrency: "unbounded"
|
|
1660
|
-
})(channels, constVoid);
|
|
1661
|
-
|
|
1662
|
-
/** @internal */
|
|
1663
|
-
const mergeAllUnboundedWith = (channels, f) => mergeAllWith({
|
|
1664
|
-
concurrency: "unbounded"
|
|
1665
|
-
})(channels, f);
|
|
1666
|
-
|
|
1667
|
-
/** @internal */
|
|
1668
|
-
const mergeAllWith = ({
|
|
1669
|
-
bufferSize = 16,
|
|
1670
|
-
concurrency,
|
|
1671
|
-
mergeStrategy = BackPressure()
|
|
1672
|
-
}) => (channels, f) => pipe(gen(function* ($) {
|
|
1673
|
-
const input = yield* $(make$2());
|
|
1674
|
-
const queueReader = fromInput(input);
|
|
1675
|
-
const queue = yield* $(acquireRelease(bounded(bufferSize), queue => shutdown(queue)));
|
|
1676
|
-
const cancelers = yield* $(acquireRelease(unbounded(), queue => shutdown(queue)));
|
|
1677
|
-
const lastDone = yield* $(make$1(none()));
|
|
1678
|
-
const errorSignal = yield* $(make());
|
|
1679
|
-
const withPermits = concurrency === "unbounded" ? _ => identity : (yield* $(makeSemaphore(concurrency))).withPermits;
|
|
1680
|
-
const pull = yield* $(toPull(channels));
|
|
1681
|
-
const evaluatePull = pull => pipe(flatMap$2(pull, match({
|
|
1682
|
-
onLeft: done => succeed$3(some$1(done)),
|
|
1683
|
-
onRight: outElem => as$2(offer(queue, succeed$3(right(outElem))), none())
|
|
1684
|
-
})), repeatUntil(isSome), flatMap$2(match$2({
|
|
1685
|
-
onNone: () => unit$1,
|
|
1686
|
-
onSome: outDone => update(lastDone, match$2({
|
|
1687
|
-
onNone: () => some$1(outDone),
|
|
1688
|
-
onSome: lastDone => some$1(f(lastDone, outDone))
|
|
1689
|
-
}))
|
|
1690
|
-
})), catchAllCause$1(cause => isInterrupted(cause) ? failCause$3(cause) : pipe(offer(queue, failCause$3(cause)), zipRight$3(succeed$4(errorSignal, void 0)), asUnit$1)));
|
|
1691
|
-
yield* $(matchCauseEffect(pull, {
|
|
1692
|
-
onFailure: cause => pipe(offer(queue, failCause$3(cause)), zipRight$3(succeed$3(false))),
|
|
1693
|
-
onSuccess: match({
|
|
1694
|
-
onLeft: outDone => raceWith$1(_await(errorSignal), withPermits(concurrency)(unit$1), {
|
|
1695
|
-
onSelfDone: (_, permitAcquisition) => pipe(interrupt(permitAcquisition), as$2(false)),
|
|
1696
|
-
onOtherDone: (_, failureAwait) => pipe(interrupt(failureAwait), zipRight$3(pipe(get(lastDone), flatMap$2(match$2({
|
|
1697
|
-
onNone: () => offer(queue, succeed$3(left(outDone))),
|
|
1698
|
-
onSome: lastDone => offer(queue, succeed$3(left(f(lastDone, outDone))))
|
|
1699
|
-
})), as$2(false))))
|
|
1700
|
-
}),
|
|
1701
|
-
onRight: channel => pipe(mergeStrategy, match$3({
|
|
1702
|
-
onBackPressure: () => gen(function* ($) {
|
|
1703
|
-
const latch = yield* $(make());
|
|
1704
|
-
const raceEffects = pipe(queueReader, pipeTo(channel), toPull, flatMap$2(pull => pipe(evaluatePull(pull), race$1(_await(errorSignal)))), scoped$1);
|
|
1705
|
-
yield* $(succeed$4(latch, void 0), zipRight$3(raceEffects), withPermits(1), forkScoped);
|
|
1706
|
-
yield* $(_await(latch));
|
|
1707
|
-
const errored = yield* $(isDone(errorSignal));
|
|
1708
|
-
return !errored;
|
|
1709
|
-
}),
|
|
1710
|
-
onBufferSliding: () => gen(function* ($) {
|
|
1711
|
-
const canceler = yield* $(make());
|
|
1712
|
-
const latch = yield* $(make());
|
|
1713
|
-
const size$1 = yield* $(size(cancelers));
|
|
1714
|
-
yield* $(take$1(cancelers), flatMap$2(_ => succeed$4(_, void 0)), when(() => concurrency === "unbounded" ? false : size$1 >= concurrency));
|
|
1715
|
-
yield* $(offer(cancelers, canceler));
|
|
1716
|
-
const raceEffects = pipe(queueReader, pipeTo(channel), toPull, flatMap$2(pull => pipe(evaluatePull(pull), race$1(_await(errorSignal)), race$1(_await(canceler)))), scoped$1);
|
|
1717
|
-
yield* $(succeed$4(latch, void 0), zipRight$3(raceEffects), withPermits(1), forkScoped);
|
|
1718
|
-
yield* $(_await(latch));
|
|
1719
|
-
const errored = yield* $(isDone(errorSignal));
|
|
1720
|
-
return !errored;
|
|
1721
|
-
})
|
|
1722
|
-
}))
|
|
1723
|
-
})
|
|
1724
|
-
}), repeatWhile(identity), forkScoped);
|
|
1725
|
-
return [queue, input];
|
|
1726
|
-
}), map$2(([queue, input]) => {
|
|
1727
|
-
const consumer = pipe(take$1(queue), flatten$1, matchCause({
|
|
1728
|
-
onFailure: failCause$1,
|
|
1729
|
-
onSuccess: match({
|
|
1730
|
-
onLeft: succeedNow,
|
|
1731
|
-
onRight: outElem => flatMap$1(write(outElem), () => consumer)
|
|
1732
|
-
})
|
|
1733
|
-
}), unwrap$1);
|
|
1734
|
-
return embedInput(consumer, input);
|
|
1735
|
-
}), unwrapScoped$1);
|
|
1736
|
-
|
|
1737
|
-
/** @internal */
|
|
1738
|
-
const mergeMap = /*#__PURE__*/dual(3, (self, f, options) => mergeAll(options)(mapOut(self, f)));
|
|
1739
|
-
|
|
1740
|
-
/** @internal */
|
|
1741
|
-
const mergeOut = /*#__PURE__*/dual(2, (self, n) => mergeAll({
|
|
1742
|
-
concurrency: n
|
|
1743
|
-
})(mapOut(self, identity)));
|
|
1744
|
-
|
|
1745
|
-
/** @internal */
|
|
1746
|
-
const mergeOutWith = /*#__PURE__*/dual(3, (self, n, f) => mergeAllWith({
|
|
1747
|
-
concurrency: n
|
|
1748
|
-
})(mapOut(self, identity), f));
|
|
1749
|
-
|
|
1750
|
-
/** @internal */
|
|
1751
|
-
const mergeWith = /*#__PURE__*/dual(2, (self, options) => unwrapScoped$1(flatMap$2(make$2(), input => {
|
|
1752
|
-
const queueReader = fromInput(input);
|
|
1753
|
-
return map$2(zip$2(toPull(pipeTo(queueReader, self)), toPull(pipeTo(queueReader, options.other))), ([pullL, pullR]) => {
|
|
1754
|
-
const handleSide = (exit, fiber, pull) => (done, both, single) => {
|
|
1755
|
-
const onDecision = decision => {
|
|
1756
|
-
const op = decision;
|
|
1757
|
-
if (op._tag === OP_DONE$1) {
|
|
1758
|
-
return succeed$3(fromEffect$1(zipRight$3(interrupt(fiber), op.effect)));
|
|
1759
|
-
}
|
|
1760
|
-
return map$2(_await$1(fiber), match$1({
|
|
1761
|
-
onFailure: cause => fromEffect$1(op.f(failCause$2(cause))),
|
|
1762
|
-
onSuccess: match({
|
|
1763
|
-
onLeft: done => fromEffect$1(op.f(succeed$2(done))),
|
|
1764
|
-
onRight: elem => zipRight$1(write(elem), go(single(op.f)))
|
|
1765
|
-
})
|
|
1766
|
-
}));
|
|
1767
|
-
};
|
|
1768
|
-
return match$1(exit, {
|
|
1769
|
-
onFailure: cause => onDecision(done(failCause$2(cause))),
|
|
1770
|
-
onSuccess: match({
|
|
1771
|
-
onLeft: z => onDecision(done(succeed$2(z))),
|
|
1772
|
-
onRight: elem => succeed$3(flatMap$1(write(elem), () => flatMap$1(fromEffect$1(forkDaemon(pull)), leftFiber => go(both(leftFiber, fiber)))))
|
|
1773
|
-
})
|
|
1774
|
-
});
|
|
1775
|
-
};
|
|
1776
|
-
const go = state => {
|
|
1777
|
-
switch (state._tag) {
|
|
1778
|
-
case OP_BOTH_RUNNING:
|
|
1779
|
-
{
|
|
1780
|
-
const leftJoin = interruptible(join(state.left));
|
|
1781
|
-
const rightJoin = interruptible(join(state.right));
|
|
1782
|
-
return unwrap$1(raceWith$1(leftJoin, rightJoin, {
|
|
1783
|
-
onSelfDone: (leftExit, rf) => zipRight$3(interrupt(rf), handleSide(leftExit, state.right, pullL)(options.onSelfDone, BothRunning, f => LeftDone(f))),
|
|
1784
|
-
onOtherDone: (rightExit, lf) => zipRight$3(interrupt(lf), handleSide(rightExit, state.left, pullR)(options.onOtherDone, (left, right) => BothRunning(right, left), f => RightDone(f)))
|
|
1785
|
-
}));
|
|
1786
|
-
}
|
|
1787
|
-
case OP_LEFT_DONE:
|
|
1788
|
-
{
|
|
1789
|
-
return unwrap$1(map$2(exit(pullR), match$1({
|
|
1790
|
-
onFailure: cause => fromEffect$1(state.f(failCause$2(cause))),
|
|
1791
|
-
onSuccess: match({
|
|
1792
|
-
onLeft: done => fromEffect$1(state.f(succeed$2(done))),
|
|
1793
|
-
onRight: elem => flatMap$1(write(elem), () => go(LeftDone(state.f)))
|
|
1794
|
-
})
|
|
1795
|
-
})));
|
|
1796
|
-
}
|
|
1797
|
-
case OP_RIGHT_DONE:
|
|
1798
|
-
{
|
|
1799
|
-
return unwrap$1(map$2(exit(pullL), match$1({
|
|
1800
|
-
onFailure: cause => fromEffect$1(state.f(failCause$2(cause))),
|
|
1801
|
-
onSuccess: match({
|
|
1802
|
-
onLeft: done => fromEffect$1(state.f(succeed$2(done))),
|
|
1803
|
-
onRight: elem => flatMap$1(write(elem), () => go(RightDone(state.f)))
|
|
1804
|
-
})
|
|
1805
|
-
})));
|
|
1806
|
-
}
|
|
1807
|
-
}
|
|
1808
|
-
};
|
|
1809
|
-
return pipe(fromEffect$1(zipWith$1(forkDaemon(pullL), forkDaemon(pullR), (left, right) => BothRunning(left, right))), flatMap$1(go), embedInput(input));
|
|
1810
|
-
});
|
|
1811
|
-
})));
|
|
1812
|
-
|
|
1813
|
-
/** @internal */
|
|
1814
|
-
const never$1 = /*#__PURE__*/fromEffect$1(never$2);
|
|
1815
|
-
|
|
1816
|
-
/** @internal */
|
|
1817
|
-
const orDie = /*#__PURE__*/dual(2, (self, error) => orDieWith(self, error));
|
|
1818
|
-
|
|
1819
|
-
/** @internal */
|
|
1820
|
-
const orDieWith = /*#__PURE__*/dual(2, (self, f) => catchAll(self, e => {
|
|
1821
|
-
throw f(e);
|
|
1822
|
-
}));
|
|
1823
|
-
|
|
1824
|
-
/** @internal */
|
|
1825
|
-
const orElse$1 = /*#__PURE__*/dual(2, (self, that) => catchAll(self, that));
|
|
1826
|
-
|
|
1827
|
-
/** @internal */
|
|
1828
|
-
const pipeToOrFail = /*#__PURE__*/dual(2, (self, that) => suspend$1(() => {
|
|
1829
|
-
let channelException = undefined;
|
|
1830
|
-
const reader = readWith({
|
|
1831
|
-
onInput: outElem => flatMap$1(write(outElem), () => reader),
|
|
1832
|
-
onFailure: outErr => {
|
|
1833
|
-
channelException = ChannelException(outErr);
|
|
1834
|
-
return failCause$1(die$2(channelException));
|
|
1835
|
-
},
|
|
1836
|
-
onDone: succeedNow
|
|
1837
|
-
});
|
|
1838
|
-
const writer = readWithCause({
|
|
1839
|
-
onInput: outElem => pipe(write(outElem), flatMap$1(() => writer)),
|
|
1840
|
-
onFailure: cause => isDieType(cause) && isChannelException(cause.defect) && equals(cause.defect, channelException) ? fail$1(cause.defect.error) : failCause$1(cause),
|
|
1841
|
-
onDone: succeedNow
|
|
1842
|
-
});
|
|
1843
|
-
return pipeTo(pipeTo(pipeTo(self, reader), that), writer);
|
|
1844
|
-
}));
|
|
1845
|
-
|
|
1846
|
-
/** @internal */
|
|
1847
|
-
const provideService = /*#__PURE__*/dual(3, (self, tag, service) => {
|
|
1848
|
-
return flatMap$1(context$1(), context => provideContext$1(self, add(context, tag, service)));
|
|
1849
|
-
});
|
|
1850
|
-
|
|
1851
|
-
/** @internal */
|
|
1852
|
-
const provideLayer = /*#__PURE__*/dual(2, (self, layer) => unwrapScoped$1(map$2(build(layer), env => provideContext$1(self, env))));
|
|
1853
|
-
|
|
1854
|
-
/** @internal */
|
|
1855
|
-
const mapInputContext = /*#__PURE__*/dual(2, (self, f) => contextWithChannel(context => provideContext$1(self, f(context))));
|
|
1856
|
-
|
|
1857
|
-
/** @internal */
|
|
1858
|
-
const provideSomeLayer = /*#__PURE__*/dual(2, (self, layer) =>
|
|
1859
|
-
// @ts-expect-error
|
|
1860
|
-
provideLayer(self, merge(context$3(), layer)));
|
|
1861
|
-
|
|
1862
|
-
/** @internal */
|
|
1863
|
-
const read = () => readOrFail(none());
|
|
1864
|
-
|
|
1865
|
-
/** @internal */
|
|
1866
|
-
const repeated = self => flatMap$1(self, () => repeated(self));
|
|
1867
|
-
|
|
1868
|
-
/** @internal */
|
|
1869
|
-
const run = self => scoped$1(runScoped(self));
|
|
1870
|
-
|
|
1871
|
-
/** @internal */
|
|
1872
|
-
const runCollect = self => run$1(collectElements(self));
|
|
1873
|
-
|
|
1874
|
-
/** @internal */
|
|
1875
|
-
const runDrain = self => run$1(drain$1(self));
|
|
1876
|
-
|
|
1877
|
-
/** @internal */
|
|
1878
|
-
const scoped = effect => unwrap$1(uninterruptibleMask(restore => map$2(make$3(), scope => acquireReleaseOut(tapErrorCause(restore(extend(scope)(effect)), cause => close(scope, failCause$2(cause))), (_, exit) => close(scope, exit)))));
|
|
1879
|
-
|
|
1880
|
-
/** @internal */
|
|
1881
|
-
const toHub = hub => toQueue(hub);
|
|
1882
|
-
|
|
1883
|
-
/** @internal */
|
|
1884
|
-
const toPull = self => map$2(acquireRelease(sync$2(() => new ChannelExecutor(self, void 0, identity)), (exec, exit) => {
|
|
1885
|
-
const finalize = exec.close(exit);
|
|
1886
|
-
return finalize === undefined ? unit$1 : finalize;
|
|
1887
|
-
}), exec => suspend$2(() => interpretToPull(exec.run(), exec)));
|
|
1888
|
-
|
|
1889
|
-
/** @internal */
|
|
1890
|
-
const interpretToPull = (channelState, exec) => {
|
|
1891
|
-
const state = channelState;
|
|
1892
|
-
switch (state._tag) {
|
|
1893
|
-
case OP_DONE:
|
|
1894
|
-
{
|
|
1895
|
-
return match$1(exec.getDone(), {
|
|
1896
|
-
onFailure: failCause$3,
|
|
1897
|
-
onSuccess: done => succeed$3(left(done))
|
|
1898
|
-
});
|
|
1899
|
-
}
|
|
1900
|
-
case OP_EMIT$1:
|
|
1901
|
-
{
|
|
1902
|
-
return succeed$3(right(exec.getEmit()));
|
|
1903
|
-
}
|
|
1904
|
-
case OP_FROM_EFFECT:
|
|
1905
|
-
{
|
|
1906
|
-
return pipe(state.effect, flatMap$2(() => interpretToPull(exec.run(), exec)));
|
|
1907
|
-
}
|
|
1908
|
-
case OP_READ:
|
|
1909
|
-
{
|
|
1910
|
-
return readUpstream(state, () => interpretToPull(exec.run(), exec), cause => failCause$3(cause));
|
|
1911
|
-
}
|
|
1912
|
-
}
|
|
1913
|
-
};
|
|
1914
|
-
|
|
1915
|
-
/** @internal */
|
|
1916
|
-
const toQueue = queue => suspend$1(() => toQueueInternal(queue));
|
|
1917
|
-
|
|
1918
|
-
/** @internal */
|
|
1919
|
-
const toQueueInternal = queue => {
|
|
1920
|
-
return readWithCause({
|
|
1921
|
-
onInput: elem => flatMap$1(fromEffect$1(offer(queue, right(elem))), () => toQueueInternal(queue)),
|
|
1922
|
-
onFailure: cause => fromEffect$1(pipe(offer(queue, left(failCause$2(cause))))),
|
|
1923
|
-
onDone: done => fromEffect$1(pipe(offer(queue, left(succeed$2(done)))))
|
|
1924
|
-
});
|
|
1925
|
-
};
|
|
1926
|
-
|
|
1927
|
-
/** @internal */
|
|
1928
|
-
const unwrap$1 = channel => flatten(fromEffect$1(channel));
|
|
1929
|
-
|
|
1930
|
-
/** @internal */
|
|
1931
|
-
const unwrapScoped$1 = self => concatAllWith(scoped(self), (d, _) => d, (d, _) => d);
|
|
1932
|
-
|
|
1933
|
-
/** @internal */
|
|
1934
|
-
const updateService = /*#__PURE__*/dual(3, (self, tag, f) => mapInputContext(self, context => merge$1(context, make$4(tag, f(unsafeGet(context, tag))))));
|
|
1935
|
-
|
|
1936
|
-
/** @internal */
|
|
1937
|
-
const withSpan = /*#__PURE__*/dual(3, (self, name, options) => unwrapScoped$1(as$2(withSpanScoped(name, options), self)));
|
|
1938
|
-
|
|
1939
|
-
/** @internal */
|
|
1940
|
-
const writeAll = (...outs) => writeChunk(fromIterable(outs));
|
|
1941
|
-
|
|
1942
|
-
/** @internal */
|
|
1943
|
-
const writeChunk = outs => writeChunkWriter(0, outs.length, outs);
|
|
1944
|
-
|
|
1945
|
-
/** @internal */
|
|
1946
|
-
const writeChunkWriter = (idx, len, chunk) => {
|
|
1947
|
-
return idx === len ? unit : pipe(write(pipe(chunk, unsafeGet$1(idx))), flatMap$1(() => writeChunkWriter(idx + 1, len, chunk)));
|
|
1948
|
-
};
|
|
1949
|
-
|
|
1950
|
-
/** @internal */
|
|
1951
|
-
const zip$1 = /*#__PURE__*/dual(args => isChannel(args[1]), (self, that, options) => options?.concurrent ? mergeWith(self, {
|
|
1952
|
-
other: that,
|
|
1953
|
-
onSelfDone: exit1 => Await(exit2 => suspend$2(() => zip$3(exit1, exit2))),
|
|
1954
|
-
onOtherDone: exit2 => Await(exit1 => suspend$2(() => zip$3(exit1, exit2)))
|
|
1955
|
-
}) : flatMap$1(self, a => map$1(that, b => [a, b])));
|
|
1956
|
-
|
|
1957
|
-
/** @internal */
|
|
1958
|
-
const zipLeft$1 = /*#__PURE__*/dual(args => isChannel(args[1]), (self, that, options) => options?.concurrent ? map$1(zip$1(self, that, {
|
|
1959
|
-
concurrent: true
|
|
1960
|
-
}), tuple => tuple[0]) : flatMap$1(self, z => as$1(that, z)));
|
|
1961
|
-
|
|
1962
|
-
/** @internal */
|
|
1963
|
-
const zipRight$1 = /*#__PURE__*/dual(args => isChannel(args[1]), (self, that, options) => options?.concurrent ? map$1(zip$1(self, that, {
|
|
1964
|
-
concurrent: true
|
|
1965
|
-
}), tuple => tuple[1]) : flatMap$1(self, () => that));
|
|
1966
|
-
|
|
1967
|
-
/** @internal */
|
|
1968
|
-
const ChannelExceptionTypeId = /*#__PURE__*/Symbol.for("effect/Channel/ChannelException");
|
|
1969
|
-
|
|
1970
|
-
/** @internal */
|
|
1971
|
-
const ChannelException = error => ({
|
|
1972
|
-
_tag: "ChannelException",
|
|
1973
|
-
[ChannelExceptionTypeId]: ChannelExceptionTypeId,
|
|
1974
|
-
error
|
|
1975
|
-
});
|
|
1976
|
-
|
|
1977
|
-
/** @internal */
|
|
1978
|
-
const isChannelException = u => typeof u === "object" && u != null && ChannelExceptionTypeId in u;
|
|
1979
|
-
|
|
1980
|
-
/** @internal */
|
|
1981
|
-
const SinkTypeId = /*#__PURE__*/Symbol.for("effect/Sink");
|
|
1982
|
-
|
|
1983
|
-
/** @internal */
|
|
1984
|
-
const sinkVariance = {
|
|
1985
|
-
_R: _ => _,
|
|
1986
|
-
_E: _ => _,
|
|
1987
|
-
_In: _ => _,
|
|
1988
|
-
_L: _ => _,
|
|
1989
|
-
_Z: _ => _
|
|
1990
|
-
};
|
|
1991
|
-
|
|
1992
|
-
/** @internal */
|
|
1993
|
-
class SinkImpl {
|
|
1994
|
-
[SinkTypeId] = sinkVariance;
|
|
1995
|
-
constructor(channel) {
|
|
1996
|
-
this.channel = channel;
|
|
1997
|
-
}
|
|
1998
|
-
pipe() {
|
|
1999
|
-
return pipeArguments(this, arguments);
|
|
2000
|
-
}
|
|
2001
|
-
}
|
|
2002
|
-
|
|
2003
|
-
/** @internal */
|
|
2004
|
-
const isSink = u => typeof u === "object" && u != null && SinkTypeId in u;
|
|
2005
|
-
|
|
2006
|
-
/** @internal */
|
|
2007
|
-
const suspend = evaluate => new SinkImpl(suspend$1(() => toChannel(evaluate())));
|
|
2008
|
-
|
|
2009
|
-
/** @internal */
|
|
2010
|
-
const as = /*#__PURE__*/dual(2, (self, z) => pipe(self, map(() => z)));
|
|
2011
|
-
|
|
2012
|
-
/** @internal */
|
|
2013
|
-
const collectAll = () => new SinkImpl(collectAllLoop(empty()));
|
|
2014
|
-
|
|
2015
|
-
/** @internal */
|
|
2016
|
-
const collectAllLoop = acc => readWithCause({
|
|
2017
|
-
onInput: chunk => collectAllLoop(pipe(acc, appendAll(chunk))),
|
|
2018
|
-
onFailure: failCause$1,
|
|
2019
|
-
onDone: () => succeed$1(acc)
|
|
2020
|
-
});
|
|
2021
|
-
|
|
2022
|
-
/** @internal */
|
|
2023
|
-
const collectAllN = n => suspend(() => fromChannel(collectAllNLoop(n, empty())));
|
|
2024
|
-
|
|
2025
|
-
/** @internal */
|
|
2026
|
-
const collectAllNLoop = (n, acc) => readWithCause({
|
|
2027
|
-
onInput: chunk => {
|
|
2028
|
-
const [collected, leftovers] = splitAt(chunk, n);
|
|
2029
|
-
if (collected.length < n) {
|
|
2030
|
-
return collectAllNLoop(n - collected.length, appendAll(acc, collected));
|
|
2031
|
-
}
|
|
2032
|
-
if (isEmpty(leftovers)) {
|
|
2033
|
-
return succeed$1(appendAll(acc, collected));
|
|
2034
|
-
}
|
|
2035
|
-
return flatMap$1(write(leftovers), () => succeed$1(appendAll(acc, collected)));
|
|
2036
|
-
},
|
|
2037
|
-
onFailure: failCause$1,
|
|
2038
|
-
onDone: () => succeed$1(acc)
|
|
2039
|
-
});
|
|
2040
|
-
|
|
2041
|
-
/** @internal */
|
|
2042
|
-
const collectAllFrom = self => collectAllWhileWith(self, {
|
|
2043
|
-
initial: empty(),
|
|
2044
|
-
while: constTrue,
|
|
2045
|
-
body: (chunk, z) => pipe(chunk, append(z))
|
|
2046
|
-
});
|
|
2047
|
-
|
|
2048
|
-
/** @internal */
|
|
2049
|
-
const collectAllToMap = (key, merge) => {
|
|
2050
|
-
return pipe(foldLeftChunks(empty$1(), (map, chunk) => pipe(chunk, reduce(map, (map, input) => {
|
|
2051
|
-
const k = key(input);
|
|
2052
|
-
const v = pipe(map, has(k)) ? merge(pipe(map, unsafeGet$2(k)), input) : input;
|
|
2053
|
-
return pipe(map, set$1(k, v));
|
|
2054
|
-
}))));
|
|
2055
|
-
};
|
|
2056
|
-
|
|
2057
|
-
/** @internal */
|
|
2058
|
-
const collectAllToMapN = (n, key, merge) => {
|
|
2059
|
-
return foldWeighted({
|
|
2060
|
-
initial: empty$1(),
|
|
2061
|
-
maxCost: n,
|
|
2062
|
-
cost: (acc, input) => pipe(acc, has(key(input))) ? 0 : 1,
|
|
2063
|
-
body: (acc, input) => {
|
|
2064
|
-
const k = key(input);
|
|
2065
|
-
const v = pipe(acc, has(k)) ? merge(pipe(acc, unsafeGet$2(k)), input) : input;
|
|
2066
|
-
return pipe(acc, set$1(k, v));
|
|
2067
|
-
}
|
|
2068
|
-
});
|
|
2069
|
-
};
|
|
2070
|
-
|
|
2071
|
-
/** @internal */
|
|
2072
|
-
const collectAllToSet = () => foldLeftChunks(empty$2(), (acc, chunk) => pipe(chunk, reduce(acc, (acc, input) => pipe(acc, add$1(input)))));
|
|
2073
|
-
|
|
2074
|
-
/** @internal */
|
|
2075
|
-
const collectAllToSetN = n => foldWeighted({
|
|
2076
|
-
initial: empty$2(),
|
|
2077
|
-
maxCost: n,
|
|
2078
|
-
cost: (acc, input) => has$1(acc, input) ? 0 : 1,
|
|
2079
|
-
body: (acc, input) => add$1(acc, input)
|
|
2080
|
-
});
|
|
2081
|
-
|
|
2082
|
-
/** @internal */
|
|
2083
|
-
const collectAllUntil = p => {
|
|
2084
|
-
return pipe(fold([empty(), true], tuple => tuple[1], ([chunk, _], input) => [pipe(chunk, append(input)), !p(input)]), map(tuple => tuple[0]));
|
|
2085
|
-
};
|
|
2086
|
-
|
|
2087
|
-
/** @internal */
|
|
2088
|
-
const collectAllUntilEffect = p => {
|
|
2089
|
-
return pipe(foldEffect([empty(), true], tuple => tuple[1], ([chunk, _], input) => pipe(p(input), map$2(bool => [pipe(chunk, append(input)), !bool]))), map(tuple => tuple[0]));
|
|
2090
|
-
};
|
|
2091
|
-
|
|
2092
|
-
/** @internal */
|
|
2093
|
-
const collectAllWhile = predicate => fromChannel(collectAllWhileReader(predicate, empty()));
|
|
2094
|
-
|
|
2095
|
-
/** @internal */
|
|
2096
|
-
const collectAllWhileReader = (predicate, done) => readWith({
|
|
2097
|
-
onInput: input => {
|
|
2098
|
-
const [collected, leftovers] = pipe(toReadonlyArray(input), span(predicate));
|
|
2099
|
-
if (leftovers.length === 0) {
|
|
2100
|
-
return collectAllWhileReader(predicate, pipe(done, appendAll(unsafeFromArray(collected))));
|
|
2101
|
-
}
|
|
2102
|
-
return pipe(write(unsafeFromArray(leftovers)), zipRight$1(succeed$1(pipe(done, appendAll(unsafeFromArray(collected))))));
|
|
2103
|
-
},
|
|
2104
|
-
onFailure: fail$1,
|
|
2105
|
-
onDone: () => succeed$1(done)
|
|
2106
|
-
});
|
|
2107
|
-
|
|
2108
|
-
/** @internal */
|
|
2109
|
-
const collectAllWhileEffect = predicate => fromChannel(collectAllWhileEffectReader(predicate, empty()));
|
|
2110
|
-
|
|
2111
|
-
/** @internal */
|
|
2112
|
-
const collectAllWhileEffectReader = (predicate, done) => readWith({
|
|
2113
|
-
onInput: input => pipe(fromEffect$1(pipe(input, takeWhile(predicate), map$2(unsafeFromArray))), flatMap$1(collected => {
|
|
2114
|
-
const leftovers = pipe(input, drop$1(collected.length));
|
|
2115
|
-
if (isEmpty(leftovers)) {
|
|
2116
|
-
return collectAllWhileEffectReader(predicate, pipe(done, appendAll(collected)));
|
|
2117
|
-
}
|
|
2118
|
-
return pipe(write(leftovers), zipRight$1(succeed$1(pipe(done, appendAll(collected)))));
|
|
2119
|
-
})),
|
|
2120
|
-
onFailure: fail$1,
|
|
2121
|
-
onDone: () => succeed$1(done)
|
|
2122
|
-
});
|
|
2123
|
-
|
|
2124
|
-
/** @internal */
|
|
2125
|
-
const collectAllWhileWith = /*#__PURE__*/dual(2, (self, options) => {
|
|
2126
|
-
const refs = pipe(make$1(empty()), zip$2(make$1(false)));
|
|
2127
|
-
const newChannel = pipe(fromEffect$1(refs), flatMap$1(([leftoversRef, upstreamDoneRef]) => {
|
|
2128
|
-
const upstreamMarker = readWith({
|
|
2129
|
-
onInput: input => pipe(write(input), flatMap$1(() => upstreamMarker)),
|
|
2130
|
-
onFailure: fail$1,
|
|
2131
|
-
onDone: done => pipe(fromEffect$1(set(upstreamDoneRef, true)), as$1(done))
|
|
2132
|
-
});
|
|
2133
|
-
return pipe(upstreamMarker, pipeTo(bufferChunk(leftoversRef)), pipeTo(collectAllWhileWithLoop(self, leftoversRef, upstreamDoneRef, options.initial, options.while, options.body)));
|
|
2134
|
-
}));
|
|
2135
|
-
return new SinkImpl(newChannel);
|
|
2136
|
-
});
|
|
2137
|
-
|
|
2138
|
-
/** @internal */
|
|
2139
|
-
const collectAllWhileWithLoop = (self, leftoversRef, upstreamDoneRef, currentResult, p, f) => {
|
|
2140
|
-
return pipe(toChannel(self), doneCollect, foldChannel({
|
|
2141
|
-
onFailure: fail$1,
|
|
2142
|
-
onSuccess: ([leftovers, doneValue]) => p(doneValue) ? pipe(fromEffect$1(set(leftoversRef, flatten$2(leftovers))), flatMap$1(() => pipe(fromEffect$1(get(upstreamDoneRef)), flatMap$1(upstreamDone => {
|
|
2143
|
-
const accumulatedResult = f(currentResult, doneValue);
|
|
2144
|
-
return upstreamDone ? pipe(write(flatten$2(leftovers)), as$1(accumulatedResult)) : collectAllWhileWithLoop(self, leftoversRef, upstreamDoneRef, accumulatedResult, p, f);
|
|
2145
|
-
})))) : pipe(write(flatten$2(leftovers)), as$1(currentResult))
|
|
2146
|
-
}));
|
|
2147
|
-
};
|
|
2148
|
-
|
|
2149
|
-
/** @internal */
|
|
2150
|
-
const collectLeftover = self => new SinkImpl(pipe(collectElements(toChannel(self)), map$1(([chunks, z]) => [z, flatten$2(chunks)])));
|
|
2151
|
-
|
|
2152
|
-
/** @internal */
|
|
2153
|
-
const mapInput = /*#__PURE__*/dual(2, (self, f) => pipe(self, mapInputChunks(map$5(f))));
|
|
2154
|
-
|
|
2155
|
-
/** @internal */
|
|
2156
|
-
const mapInputEffect = /*#__PURE__*/dual(2, (self, f) => mapInputChunksEffect(self, chunk => map$2(forEach$1(chunk, v => f(v)), unsafeFromArray)));
|
|
2157
|
-
|
|
2158
|
-
/** @internal */
|
|
2159
|
-
const mapInputChunks = /*#__PURE__*/dual(2, (self, f) => {
|
|
2160
|
-
const loop = readWith({
|
|
2161
|
-
onInput: chunk => pipe(write(f(chunk)), flatMap$1(() => loop)),
|
|
2162
|
-
onFailure: fail$1,
|
|
2163
|
-
onDone: succeed$1
|
|
2164
|
-
});
|
|
2165
|
-
return new SinkImpl(pipe(loop, pipeTo(toChannel(self))));
|
|
2166
|
-
});
|
|
2167
|
-
|
|
2168
|
-
/** @internal */
|
|
2169
|
-
const mapInputChunksEffect = /*#__PURE__*/dual(2, (self, f) => {
|
|
2170
|
-
const loop = readWith({
|
|
2171
|
-
onInput: chunk => pipe(fromEffect$1(f(chunk)), flatMap$1(write), flatMap$1(() => loop)),
|
|
2172
|
-
onFailure: fail$1,
|
|
2173
|
-
onDone: succeed$1
|
|
2174
|
-
});
|
|
2175
|
-
return new SinkImpl(pipe(loop, pipeToOrFail(toChannel(self))));
|
|
2176
|
-
});
|
|
2177
|
-
|
|
2178
|
-
/** @internal */
|
|
2179
|
-
const die = defect => failCause(die$2(defect));
|
|
2180
|
-
|
|
2181
|
-
/** @internal */
|
|
2182
|
-
const dieMessage = message => failCause(die$2(RuntimeException(message)));
|
|
2183
|
-
|
|
2184
|
-
/** @internal */
|
|
2185
|
-
const dieSync = evaluate => failCauseSync(() => die$2(evaluate()));
|
|
2186
|
-
|
|
2187
|
-
/** @internal */
|
|
2188
|
-
const dimap = /*#__PURE__*/dual(2, (self, options) => map(mapInput(self, options.onInput), options.onDone));
|
|
2189
|
-
|
|
2190
|
-
/** @internal */
|
|
2191
|
-
const dimapEffect = /*#__PURE__*/dual(2, (self, options) => mapEffect(mapInputEffect(self, options.onInput), options.onDone));
|
|
2192
|
-
|
|
2193
|
-
/** @internal */
|
|
2194
|
-
const dimapChunks = /*#__PURE__*/dual(2, (self, options) => map(mapInputChunks(self, options.onInput), options.onDone));
|
|
2195
|
-
|
|
2196
|
-
/** @internal */
|
|
2197
|
-
const dimapChunksEffect = /*#__PURE__*/dual(2, (self, options) => mapEffect(mapInputChunksEffect(self, options.onInput), options.onDone));
|
|
2198
|
-
|
|
2199
|
-
/** @internal */
|
|
2200
|
-
const drain = /*#__PURE__*/new SinkImpl( /*#__PURE__*/drain$1( /*#__PURE__*/identityChannel()));
|
|
2201
|
-
|
|
2202
|
-
/** @internal */
|
|
2203
|
-
const drop = n => suspend(() => new SinkImpl(dropLoop(n)));
|
|
2204
|
-
|
|
2205
|
-
/** @internal */
|
|
2206
|
-
const dropLoop = n => readWith({
|
|
2207
|
-
onInput: input => {
|
|
2208
|
-
const dropped = pipe(input, drop$1(n));
|
|
2209
|
-
const leftover = Math.max(n - input.length, 0);
|
|
2210
|
-
const more = isEmpty(input) || leftover > 0;
|
|
2211
|
-
if (more) {
|
|
2212
|
-
return dropLoop(leftover);
|
|
2213
|
-
}
|
|
2214
|
-
return pipe(write(dropped), zipRight$1(identityChannel()));
|
|
2215
|
-
},
|
|
2216
|
-
onFailure: fail$1,
|
|
2217
|
-
onDone: () => unit
|
|
2218
|
-
});
|
|
2219
|
-
|
|
2220
|
-
/** @internal */
|
|
2221
|
-
const dropUntil = predicate => new SinkImpl(pipe(toChannel(dropWhile(input => !predicate(input))), pipeToOrFail(toChannel(drop(1)))));
|
|
2222
|
-
|
|
2223
|
-
/** @internal */
|
|
2224
|
-
const dropUntilEffect = predicate => suspend(() => new SinkImpl(dropUntilEffectReader(predicate)));
|
|
2225
|
-
|
|
2226
|
-
/** @internal */
|
|
2227
|
-
const dropUntilEffectReader = predicate => readWith({
|
|
2228
|
-
onInput: input => pipe(input, dropUntil$1(predicate), map$2(leftover => {
|
|
2229
|
-
const more = leftover.length === 0;
|
|
2230
|
-
return more ? dropUntilEffectReader(predicate) : pipe(write(unsafeFromArray(leftover)), zipRight$1(identityChannel()));
|
|
2231
|
-
}), unwrap$1),
|
|
2232
|
-
onFailure: fail$1,
|
|
2233
|
-
onDone: () => unit
|
|
2234
|
-
});
|
|
2235
|
-
|
|
2236
|
-
/** @internal */
|
|
2237
|
-
const dropWhile = predicate => new SinkImpl(dropWhileReader(predicate));
|
|
2238
|
-
|
|
2239
|
-
/** @internal */
|
|
2240
|
-
const dropWhileReader = predicate => readWith({
|
|
2241
|
-
onInput: input => {
|
|
2242
|
-
const out = pipe(input, dropWhile$1(predicate));
|
|
2243
|
-
if (isEmpty(out)) {
|
|
2244
|
-
return dropWhileReader(predicate);
|
|
2245
|
-
}
|
|
2246
|
-
return pipe(write(out), zipRight$1(identityChannel()));
|
|
2247
|
-
},
|
|
2248
|
-
onFailure: fail$1,
|
|
2249
|
-
onDone: succeedNow
|
|
2250
|
-
});
|
|
2251
|
-
|
|
2252
|
-
/** @internal */
|
|
2253
|
-
const dropWhileEffect = predicate => suspend(() => new SinkImpl(dropWhileEffectReader(predicate)));
|
|
2254
|
-
|
|
2255
|
-
/** @internal */
|
|
2256
|
-
const dropWhileEffectReader = predicate => readWith({
|
|
2257
|
-
onInput: input => pipe(input, dropWhile$2(predicate), map$2(leftover => {
|
|
2258
|
-
const more = leftover.length === 0;
|
|
2259
|
-
return more ? dropWhileEffectReader(predicate) : pipe(write(unsafeFromArray(leftover)), zipRight$1(identityChannel()));
|
|
2260
|
-
}), unwrap$1),
|
|
2261
|
-
onFailure: fail$1,
|
|
2262
|
-
onDone: () => unit
|
|
2263
|
-
});
|
|
2264
|
-
|
|
2265
|
-
/** @internal */
|
|
2266
|
-
const ensuring = /*#__PURE__*/dual(2, (self, finalizer) => new SinkImpl(pipe(self, toChannel, ensuring$1(finalizer))));
|
|
2267
|
-
|
|
2268
|
-
/** @internal */
|
|
2269
|
-
const ensuringWith = /*#__PURE__*/dual(2, (self, finalizer) => new SinkImpl(pipe(self, toChannel, ensuringWith$1(finalizer))));
|
|
2270
|
-
|
|
2271
|
-
/** @internal */
|
|
2272
|
-
const context = () => fromEffect(context$2());
|
|
2273
|
-
|
|
2274
|
-
/** @internal */
|
|
2275
|
-
const contextWith = f => pipe(context(), map(f));
|
|
2276
|
-
|
|
2277
|
-
/** @internal */
|
|
2278
|
-
const contextWithEffect = f => pipe(context(), mapEffect(f));
|
|
2279
|
-
|
|
2280
|
-
/** @internal */
|
|
2281
|
-
const contextWithSink = f => new SinkImpl(unwrap$1(pipe(contextWith$2(context => toChannel(f(context))))));
|
|
2282
|
-
|
|
2283
|
-
/** @internal */
|
|
2284
|
-
const every = predicate => fold(true, identity, (acc, input) => acc && predicate(input));
|
|
2285
|
-
|
|
2286
|
-
/** @internal */
|
|
2287
|
-
const fail = e => new SinkImpl(fail$1(e));
|
|
2288
|
-
|
|
2289
|
-
/** @internal */
|
|
2290
|
-
const failSync = evaluate => new SinkImpl(failSync$1(evaluate));
|
|
2291
|
-
|
|
2292
|
-
/** @internal */
|
|
2293
|
-
const failCause = cause => new SinkImpl(failCause$1(cause));
|
|
2294
|
-
|
|
2295
|
-
/** @internal */
|
|
2296
|
-
const failCauseSync = evaluate => new SinkImpl(failCauseSync$1(evaluate));
|
|
2297
|
-
|
|
2298
|
-
/** @internal */
|
|
2299
|
-
const filterInput = f => {
|
|
2300
|
-
return self => pipe(self, mapInputChunks(filter(f)));
|
|
2301
|
-
};
|
|
2302
|
-
|
|
2303
|
-
/** @internal */
|
|
2304
|
-
const filterInputEffect = /*#__PURE__*/dual(2, (self, f) => mapInputChunksEffect(self, chunk => map$2(filter$1(chunk, f), unsafeFromArray)));
|
|
2305
|
-
|
|
2306
|
-
/** @internal */
|
|
2307
|
-
const findEffect = /*#__PURE__*/dual(2, (self, f) => {
|
|
2308
|
-
const newChannel = pipe(fromEffect$1(pipe(make$1(empty()), zip$2(make$1(false)))), flatMap$1(([leftoversRef, upstreamDoneRef]) => {
|
|
2309
|
-
const upstreamMarker = readWith({
|
|
2310
|
-
onInput: input => pipe(write(input), flatMap$1(() => upstreamMarker)),
|
|
2311
|
-
onFailure: fail$1,
|
|
2312
|
-
onDone: done => pipe(fromEffect$1(set(upstreamDoneRef, true)), as$1(done))
|
|
2313
|
-
});
|
|
2314
|
-
const loop = foldChannel(collectElements(toChannel(self)), {
|
|
2315
|
-
onFailure: fail$1,
|
|
2316
|
-
onSuccess: ([leftovers, doneValue]) => pipe(fromEffect$1(f(doneValue)), flatMap$1(satisfied => pipe(fromEffect$1(set(leftoversRef, flatten$2(leftovers))), zipRight$1(pipe(fromEffect$1(get(upstreamDoneRef)), flatMap$1(upstreamDone => {
|
|
2317
|
-
if (satisfied) {
|
|
2318
|
-
return pipe(write(flatten$2(leftovers)), as$1(some$1(doneValue)));
|
|
2319
|
-
}
|
|
2320
|
-
if (upstreamDone) {
|
|
2321
|
-
return pipe(write(flatten$2(leftovers)), as$1(none()));
|
|
2322
|
-
}
|
|
2323
|
-
return loop;
|
|
2324
|
-
}))))))
|
|
2325
|
-
});
|
|
2326
|
-
return pipe(upstreamMarker, pipeTo(bufferChunk(leftoversRef)), pipeTo(loop));
|
|
2327
|
-
}));
|
|
2328
|
-
return new SinkImpl(newChannel);
|
|
2329
|
-
});
|
|
2330
|
-
|
|
2331
|
-
/** @internal */
|
|
2332
|
-
const fold = (s, contFn, f) => suspend(() => new SinkImpl(foldReader(s, contFn, f)));
|
|
2333
|
-
|
|
2334
|
-
/** @internal */
|
|
2335
|
-
const foldReader = (s, contFn, f) => {
|
|
2336
|
-
if (!contFn(s)) {
|
|
2337
|
-
return succeedNow(s);
|
|
2338
|
-
}
|
|
2339
|
-
return readWith({
|
|
2340
|
-
onInput: input => {
|
|
2341
|
-
const [nextS, leftovers] = foldChunkSplit(s, input, contFn, f, 0, input.length);
|
|
2342
|
-
if (isNonEmpty(leftovers)) {
|
|
2343
|
-
return pipe(write(leftovers), as$1(nextS));
|
|
2344
|
-
}
|
|
2345
|
-
return foldReader(nextS, contFn, f);
|
|
2346
|
-
},
|
|
2347
|
-
onFailure: fail$1,
|
|
2348
|
-
onDone: () => succeedNow(s)
|
|
2349
|
-
});
|
|
2350
|
-
};
|
|
2351
|
-
|
|
2352
|
-
/** @internal */
|
|
2353
|
-
const foldChunkSplit = (s, chunk, contFn, f, index, length) => {
|
|
2354
|
-
if (index === length) {
|
|
2355
|
-
return [s, empty()];
|
|
2356
|
-
}
|
|
2357
|
-
const s1 = f(s, pipe(chunk, unsafeGet$1(index)));
|
|
2358
|
-
if (contFn(s1)) {
|
|
2359
|
-
return foldChunkSplit(s1, chunk, contFn, f, index + 1, length);
|
|
2360
|
-
}
|
|
2361
|
-
return [s1, pipe(chunk, drop$1(index + 1))];
|
|
2362
|
-
};
|
|
2363
|
-
|
|
2364
|
-
/** @internal */
|
|
2365
|
-
const foldSink = /*#__PURE__*/dual(2, (self, options) => {
|
|
2366
|
-
const newChannel = pipe(toChannel(self), collectElements, foldChannel({
|
|
2367
|
-
onFailure: error => toChannel(options.onFailure(error)),
|
|
2368
|
-
onSuccess: ([leftovers, z]) => suspend$1(() => {
|
|
2369
|
-
const leftoversRef = {
|
|
2370
|
-
ref: pipe(leftovers, filter(isNonEmpty))
|
|
2371
|
-
};
|
|
2372
|
-
const refReader = pipe(sync$1(() => {
|
|
2373
|
-
const ref = leftoversRef.ref;
|
|
2374
|
-
leftoversRef.ref = empty();
|
|
2375
|
-
return ref;
|
|
2376
|
-
}),
|
|
2377
|
-
// This cast is safe because of the L1 >: L <: In1 bound. It follows that
|
|
2378
|
-
// L <: In1 and therefore Chunk[L] can be safely cast to Chunk[In1].
|
|
2379
|
-
flatMap$1(chunk => writeChunk(chunk)));
|
|
2380
|
-
const passthrough = identityChannel();
|
|
2381
|
-
const continuationSink = pipe(refReader, zipRight$1(passthrough), pipeTo(toChannel(options.onSuccess(z))));
|
|
2382
|
-
return flatMap$1(collectElements(continuationSink), ([newLeftovers, z1]) => pipe(succeed$1(leftoversRef.ref), flatMap$1(writeChunk), zipRight$1(writeChunk(newLeftovers)), as$1(z1)));
|
|
2383
|
-
})
|
|
2384
|
-
}));
|
|
2385
|
-
return new SinkImpl(newChannel);
|
|
2386
|
-
});
|
|
2387
|
-
|
|
2388
|
-
/** @internal */
|
|
2389
|
-
const foldChunks = (s, contFn, f) => suspend(() => new SinkImpl(foldChunksReader(s, contFn, f)));
|
|
2390
|
-
|
|
2391
|
-
/** @internal */
|
|
2392
|
-
const foldChunksReader = (s, contFn, f) => {
|
|
2393
|
-
if (!contFn(s)) {
|
|
2394
|
-
return succeedNow(s);
|
|
2395
|
-
}
|
|
2396
|
-
return readWith({
|
|
2397
|
-
onInput: input => foldChunksReader(f(s, input), contFn, f),
|
|
2398
|
-
onFailure: fail$1,
|
|
2399
|
-
onDone: () => succeedNow(s)
|
|
2400
|
-
});
|
|
2401
|
-
};
|
|
2402
|
-
|
|
2403
|
-
/** @internal */
|
|
2404
|
-
const foldChunksEffect = (s, contFn, f) => suspend(() => new SinkImpl(foldChunksEffectReader(s, contFn, f)));
|
|
2405
|
-
|
|
2406
|
-
/** @internal */
|
|
2407
|
-
const foldChunksEffectReader = (s, contFn, f) => {
|
|
2408
|
-
if (!contFn(s)) {
|
|
2409
|
-
return succeedNow(s);
|
|
2410
|
-
}
|
|
2411
|
-
return readWith({
|
|
2412
|
-
onInput: input => pipe(fromEffect$1(f(s, input)), flatMap$1(s => foldChunksEffectReader(s, contFn, f))),
|
|
2413
|
-
onFailure: fail$1,
|
|
2414
|
-
onDone: () => succeedNow(s)
|
|
2415
|
-
});
|
|
2416
|
-
};
|
|
2417
|
-
|
|
2418
|
-
/** @internal */
|
|
2419
|
-
const foldEffect = (s, contFn, f) => suspend(() => new SinkImpl(foldEffectReader(s, contFn, f)));
|
|
2420
|
-
|
|
2421
|
-
/** @internal */
|
|
2422
|
-
const foldEffectReader = (s, contFn, f) => {
|
|
2423
|
-
if (!contFn(s)) {
|
|
2424
|
-
return succeedNow(s);
|
|
2425
|
-
}
|
|
2426
|
-
return readWith({
|
|
2427
|
-
onInput: input => pipe(fromEffect$1(foldChunkSplitEffect(s, input, contFn, f)), flatMap$1(([nextS, leftovers]) => pipe(leftovers, match$2({
|
|
2428
|
-
onNone: () => foldEffectReader(nextS, contFn, f),
|
|
2429
|
-
onSome: leftover => pipe(write(leftover), as$1(nextS))
|
|
2430
|
-
})))),
|
|
2431
|
-
onFailure: fail$1,
|
|
2432
|
-
onDone: () => succeedNow(s)
|
|
2433
|
-
});
|
|
2434
|
-
};
|
|
2435
|
-
|
|
2436
|
-
/** @internal */
|
|
2437
|
-
const foldChunkSplitEffect = (s, chunk, contFn, f) => foldChunkSplitEffectInternal(s, chunk, 0, chunk.length, contFn, f);
|
|
2438
|
-
|
|
2439
|
-
/** @internal */
|
|
2440
|
-
const foldChunkSplitEffectInternal = (s, chunk, index, length, contFn, f) => {
|
|
2441
|
-
if (index === length) {
|
|
2442
|
-
return succeed$3([s, none()]);
|
|
2443
|
-
}
|
|
2444
|
-
return pipe(f(s, pipe(chunk, unsafeGet$1(index))), flatMap$2(s1 => contFn(s1) ? foldChunkSplitEffectInternal(s1, chunk, index + 1, length, contFn, f) : succeed$3([s1, some$1(pipe(chunk, drop$1(index + 1)))])));
|
|
2445
|
-
};
|
|
2446
|
-
|
|
2447
|
-
/** @internal */
|
|
2448
|
-
const foldLeft = (s, f) => ignoreLeftover(fold(s, constTrue, f));
|
|
2449
|
-
|
|
2450
|
-
/** @internal */
|
|
2451
|
-
const foldLeftChunks = (s, f) => foldChunks(s, constTrue, f);
|
|
2452
|
-
|
|
2453
|
-
/** @internal */
|
|
2454
|
-
const foldLeftChunksEffect = (s, f) => ignoreLeftover(foldChunksEffect(s, constTrue, f));
|
|
2455
|
-
|
|
2456
|
-
/** @internal */
|
|
2457
|
-
const foldLeftEffect = (s, f) => foldEffect(s, constTrue, f);
|
|
2458
|
-
|
|
2459
|
-
/** @internal */
|
|
2460
|
-
const foldUntil = (s, max, f) => pipe(fold([s, 0], tuple => tuple[1] < max, ([output, count], input) => [f(output, input), count + 1]), map(tuple => tuple[0]));
|
|
2461
|
-
|
|
2462
|
-
/** @internal */
|
|
2463
|
-
const foldUntilEffect = (s, max, f) => pipe(foldEffect([s, 0], tuple => tuple[1] < max, ([output, count], input) => pipe(f(output, input), map$2(s => [s, count + 1]))), map(tuple => tuple[0]));
|
|
2464
|
-
|
|
2465
|
-
/** @internal */
|
|
2466
|
-
const foldWeighted = options => foldWeightedDecompose({
|
|
2467
|
-
...options,
|
|
2468
|
-
decompose: of
|
|
2469
|
-
});
|
|
2470
|
-
|
|
2471
|
-
/** @internal */
|
|
2472
|
-
const foldWeightedDecompose = options => suspend(() => new SinkImpl(foldWeightedDecomposeLoop(options.initial, 0, false, options.maxCost, options.cost, options.decompose, options.body)));
|
|
2473
|
-
|
|
2474
|
-
/** @internal */
|
|
2475
|
-
const foldWeightedDecomposeLoop = (s, cost, dirty, max, costFn, decompose, f) => readWith({
|
|
2476
|
-
onInput: input => {
|
|
2477
|
-
const [nextS, nextCost, nextDirty, leftovers] = foldWeightedDecomposeFold(input, 0, s, cost, dirty, max, costFn, decompose, f);
|
|
2478
|
-
if (isNonEmpty(leftovers)) {
|
|
2479
|
-
return pipe(write(leftovers), zipRight$1(succeedNow(nextS)));
|
|
2480
|
-
}
|
|
2481
|
-
if (cost > max) {
|
|
2482
|
-
return succeedNow(nextS);
|
|
2483
|
-
}
|
|
2484
|
-
return foldWeightedDecomposeLoop(nextS, nextCost, nextDirty, max, costFn, decompose, f);
|
|
2485
|
-
},
|
|
2486
|
-
onFailure: fail$1,
|
|
2487
|
-
onDone: () => succeedNow(s)
|
|
2488
|
-
});
|
|
2489
|
-
|
|
2490
|
-
/** @internal */
|
|
2491
|
-
const foldWeightedDecomposeFold = (input, index, s, cost, dirty, max, costFn, decompose, f) => {
|
|
2492
|
-
if (index === input.length) {
|
|
2493
|
-
return [s, cost, dirty, empty()];
|
|
2494
|
-
}
|
|
2495
|
-
const elem = pipe(input, unsafeGet$1(index));
|
|
2496
|
-
const total = cost + costFn(s, elem);
|
|
2497
|
-
if (total <= max) {
|
|
2498
|
-
return foldWeightedDecomposeFold(input, index + 1, f(s, elem), total, true, max, costFn, decompose, f);
|
|
2499
|
-
}
|
|
2500
|
-
const decomposed = decompose(elem);
|
|
2501
|
-
if (decomposed.length <= 1 && !dirty) {
|
|
2502
|
-
// If `elem` cannot be decomposed, we need to cross the `max` threshold. To
|
|
2503
|
-
// minimize "injury", we only allow this when we haven't added anything else
|
|
2504
|
-
// to the aggregate (dirty = false).
|
|
2505
|
-
return [f(s, elem), total, true, pipe(input, drop$1(index + 1))];
|
|
2506
|
-
}
|
|
2507
|
-
if (decomposed.length <= 1 && dirty) {
|
|
2508
|
-
// If the state is dirty and `elem` cannot be decomposed, we stop folding
|
|
2509
|
-
// and include `elem` in the leftovers.
|
|
2510
|
-
return [s, cost, dirty, pipe(input, drop$1(index))];
|
|
2511
|
-
}
|
|
2512
|
-
// `elem` got decomposed, so we will recurse with the decomposed elements pushed
|
|
2513
|
-
// into the chunk we're processing and see if we can aggregate further.
|
|
2514
|
-
const next = pipe(decomposed, appendAll(pipe(input, drop$1(index + 1))));
|
|
2515
|
-
return foldWeightedDecomposeFold(next, 0, s, cost, dirty, max, costFn, decompose, f);
|
|
2516
|
-
};
|
|
2517
|
-
|
|
2518
|
-
/** @internal */
|
|
2519
|
-
const foldWeightedDecomposeEffect = options => suspend(() => new SinkImpl(foldWeightedDecomposeEffectLoop(options.initial, options.maxCost, options.cost, options.decompose, options.body, 0, false)));
|
|
2520
|
-
|
|
2521
|
-
/** @internal */
|
|
2522
|
-
const foldWeightedEffect = options => foldWeightedDecomposeEffect({
|
|
2523
|
-
...options,
|
|
2524
|
-
decompose: input => succeed$3(of(input))
|
|
2525
|
-
});
|
|
2526
|
-
|
|
2527
|
-
/** @internal */
|
|
2528
|
-
const foldWeightedDecomposeEffectLoop = (s, max, costFn, decompose, f, cost, dirty) => readWith({
|
|
2529
|
-
onInput: input => pipe(fromEffect$1(foldWeightedDecomposeEffectFold(s, max, costFn, decompose, f, input, dirty, cost, 0)), flatMap$1(([nextS, nextCost, nextDirty, leftovers]) => {
|
|
2530
|
-
if (isNonEmpty(leftovers)) {
|
|
2531
|
-
return pipe(write(leftovers), zipRight$1(succeedNow(nextS)));
|
|
2532
|
-
}
|
|
2533
|
-
if (cost > max) {
|
|
2534
|
-
return succeedNow(nextS);
|
|
2535
|
-
}
|
|
2536
|
-
return foldWeightedDecomposeEffectLoop(nextS, max, costFn, decompose, f, nextCost, nextDirty);
|
|
2537
|
-
})),
|
|
2538
|
-
onFailure: fail$1,
|
|
2539
|
-
onDone: () => succeedNow(s)
|
|
2540
|
-
});
|
|
2541
|
-
|
|
2542
|
-
/** @internal */
|
|
2543
|
-
const foldWeightedDecomposeEffectFold = (s, max, costFn, decompose, f, input, dirty, cost, index) => {
|
|
2544
|
-
if (index === input.length) {
|
|
2545
|
-
return succeed$3([s, cost, dirty, empty()]);
|
|
2546
|
-
}
|
|
2547
|
-
const elem = pipe(input, unsafeGet$1(index));
|
|
2548
|
-
return pipe(costFn(s, elem), map$2(newCost => cost + newCost), flatMap$2(total => {
|
|
2549
|
-
if (total <= max) {
|
|
2550
|
-
return pipe(f(s, elem), flatMap$2(s => foldWeightedDecomposeEffectFold(s, max, costFn, decompose, f, input, true, total, index + 1)));
|
|
2551
|
-
}
|
|
2552
|
-
return pipe(decompose(elem), flatMap$2(decomposed => {
|
|
2553
|
-
if (decomposed.length <= 1 && !dirty) {
|
|
2554
|
-
// If `elem` cannot be decomposed, we need to cross the `max` threshold. To
|
|
2555
|
-
// minimize "injury", we only allow this when we haven't added anything else
|
|
2556
|
-
// to the aggregate (dirty = false).
|
|
2557
|
-
return pipe(f(s, elem), map$2(s => [s, total, true, pipe(input, drop$1(index + 1))]));
|
|
2558
|
-
}
|
|
2559
|
-
if (decomposed.length <= 1 && dirty) {
|
|
2560
|
-
// If the state is dirty and `elem` cannot be decomposed, we stop folding
|
|
2561
|
-
// and include `elem` in th leftovers.
|
|
2562
|
-
return succeed$3([s, cost, dirty, pipe(input, drop$1(index))]);
|
|
2563
|
-
}
|
|
2564
|
-
// `elem` got decomposed, so we will recurse with the decomposed elements pushed
|
|
2565
|
-
// into the chunk we're processing and see if we can aggregate further.
|
|
2566
|
-
const next = pipe(decomposed, appendAll(pipe(input, drop$1(index + 1))));
|
|
2567
|
-
return foldWeightedDecomposeEffectFold(s, max, costFn, decompose, f, next, dirty, cost, 0);
|
|
2568
|
-
}));
|
|
2569
|
-
}));
|
|
2570
|
-
};
|
|
2571
|
-
|
|
2572
|
-
/** @internal */
|
|
2573
|
-
const flatMap = /*#__PURE__*/dual(2, (self, f) => foldSink(self, {
|
|
2574
|
-
onFailure: fail,
|
|
2575
|
-
onSuccess: f
|
|
2576
|
-
}));
|
|
2577
|
-
|
|
2578
|
-
/** @internal */
|
|
2579
|
-
const forEach = f => {
|
|
2580
|
-
const process = readWithCause({
|
|
2581
|
-
onInput: input => pipe(fromEffect$1(forEach$1(input, v => f(v), {
|
|
2582
|
-
discard: true
|
|
2583
|
-
})), flatMap$1(() => process)),
|
|
2584
|
-
onFailure: failCause$1,
|
|
2585
|
-
onDone: () => unit
|
|
2586
|
-
});
|
|
2587
|
-
return new SinkImpl(process);
|
|
2588
|
-
};
|
|
2589
|
-
|
|
2590
|
-
/** @internal */
|
|
2591
|
-
const forEachChunk = f => {
|
|
2592
|
-
const process = readWithCause({
|
|
2593
|
-
onInput: input => pipe(fromEffect$1(f(input)), flatMap$1(() => process)),
|
|
2594
|
-
onFailure: failCause$1,
|
|
2595
|
-
onDone: () => unit
|
|
2596
|
-
});
|
|
2597
|
-
return new SinkImpl(process);
|
|
2598
|
-
};
|
|
2599
|
-
|
|
2600
|
-
/** @internal */
|
|
2601
|
-
const forEachWhile = f => {
|
|
2602
|
-
const process = readWithCause({
|
|
2603
|
-
onInput: input => forEachWhileReader(f, input, 0, input.length, process),
|
|
2604
|
-
onFailure: failCause$1,
|
|
2605
|
-
onDone: () => unit
|
|
2606
|
-
});
|
|
2607
|
-
return new SinkImpl(process);
|
|
2608
|
-
};
|
|
2609
|
-
|
|
2610
|
-
/** @internal */
|
|
2611
|
-
const forEachWhileReader = (f, input, index, length, cont) => {
|
|
2612
|
-
if (index === length) {
|
|
2613
|
-
return cont;
|
|
2614
|
-
}
|
|
2615
|
-
return pipe(fromEffect$1(f(pipe(input, unsafeGet$1(index)))), flatMap$1(bool => bool ? forEachWhileReader(f, input, index + 1, length, cont) : write(pipe(input, drop$1(index)))), catchAll(error => pipe(write(pipe(input, drop$1(index))), zipRight$1(fail$1(error)))));
|
|
2616
|
-
};
|
|
2617
|
-
|
|
2618
|
-
/** @internal */
|
|
2619
|
-
const forEachChunkWhile = f => {
|
|
2620
|
-
const reader = readWith({
|
|
2621
|
-
onInput: input => pipe(fromEffect$1(f(input)), flatMap$1(cont => cont ? reader : unit)),
|
|
2622
|
-
onFailure: fail$1,
|
|
2623
|
-
onDone: () => unit
|
|
2624
|
-
});
|
|
2625
|
-
return new SinkImpl(reader);
|
|
2626
|
-
};
|
|
2627
|
-
|
|
2628
|
-
/** @internal */
|
|
2629
|
-
const fromChannel = channel => new SinkImpl(channel);
|
|
2630
|
-
|
|
2631
|
-
/** @internal */
|
|
2632
|
-
const fromEffect = effect => new SinkImpl(fromEffect$1(effect));
|
|
2633
|
-
|
|
2634
|
-
/** @internal */
|
|
2635
|
-
const fromHub = (hub, options) => fromQueue(hub, options);
|
|
2636
|
-
|
|
2637
|
-
/** @internal */
|
|
2638
|
-
const fromPush = push => new SinkImpl(unwrapScoped$1(pipe(push, map$2(fromPushPull))));
|
|
2639
|
-
const fromPushPull = push => readWith({
|
|
2640
|
-
onInput: input => foldChannel(fromEffect$1(push(some$1(input))), {
|
|
2641
|
-
onFailure: ([either, leftovers]) => match(either, {
|
|
2642
|
-
onLeft: error => pipe(write(leftovers), zipRight$1(fail$1(error))),
|
|
2643
|
-
onRight: z => pipe(write(leftovers), zipRight$1(succeedNow(z)))
|
|
2644
|
-
}),
|
|
2645
|
-
onSuccess: () => fromPushPull(push)
|
|
2646
|
-
}),
|
|
2647
|
-
onFailure: fail$1,
|
|
2648
|
-
onDone: () => foldChannel(fromEffect$1(push(none())), {
|
|
2649
|
-
onFailure: ([either, leftovers]) => match(either, {
|
|
2650
|
-
onLeft: error => pipe(write(leftovers), zipRight$1(fail$1(error))),
|
|
2651
|
-
onRight: z => pipe(write(leftovers), zipRight$1(succeedNow(z)))
|
|
2652
|
-
}),
|
|
2653
|
-
onSuccess: () => fromEffect$1(dieMessage$1("BUG: Sink.fromPush - please report an issue at https://github.com/Effect-TS/stream/issues"))
|
|
2654
|
-
})
|
|
2655
|
-
});
|
|
2656
|
-
|
|
2657
|
-
/** @internal */
|
|
2658
|
-
const fromQueue = (queue, options) => options?.shutdown ? unwrapScoped(map$2(acquireRelease(succeed$3(queue), shutdown), fromQueue)) : forEachChunk(input => pipe(offerAll(queue, input)));
|
|
2659
|
-
|
|
2660
|
-
/** @internal */
|
|
2661
|
-
const head = () => fold(none(), isNone, (option, input) => match$2(option, {
|
|
2662
|
-
onNone: () => some$1(input),
|
|
2663
|
-
onSome: () => option
|
|
2664
|
-
}));
|
|
2665
|
-
|
|
2666
|
-
/** @internal */
|
|
2667
|
-
const ignoreLeftover = self => new SinkImpl(drain$1(toChannel(self)));
|
|
2668
|
-
|
|
2669
|
-
/** @internal */
|
|
2670
|
-
const last = () => foldLeftChunks(none(), (s, input) => orElse$2(last$1(input), () => s));
|
|
2671
|
-
|
|
2672
|
-
/** @internal */
|
|
2673
|
-
const leftover = chunk => new SinkImpl(suspend$1(() => write(chunk)));
|
|
2674
|
-
|
|
2675
|
-
/** @internal */
|
|
2676
|
-
const map = /*#__PURE__*/dual(2, (self, f) => {
|
|
2677
|
-
return new SinkImpl(pipe(toChannel(self), map$1(f)));
|
|
2678
|
-
});
|
|
2679
|
-
|
|
2680
|
-
/** @internal */
|
|
2681
|
-
const mapEffect = /*#__PURE__*/dual(2, (self, f) => new SinkImpl(pipe(toChannel(self), mapEffect$1(f))));
|
|
2682
|
-
|
|
2683
|
-
/** @internal */
|
|
2684
|
-
const mapError = /*#__PURE__*/dual(2, (self, f) => new SinkImpl(pipe(toChannel(self), mapError$1(f))));
|
|
2685
|
-
|
|
2686
|
-
/** @internal */
|
|
2687
|
-
const mapLeftover = /*#__PURE__*/dual(2, (self, f) => new SinkImpl(pipe(toChannel(self), mapOut(map$5(f)))));
|
|
2688
|
-
|
|
2689
|
-
/** @internal */
|
|
2690
|
-
const never = /*#__PURE__*/fromEffect(never$2);
|
|
2691
|
-
|
|
2692
|
-
/** @internal */
|
|
2693
|
-
const orElse = /*#__PURE__*/dual(2, (self, that) => new SinkImpl(pipe(toChannel(self), orElse$1(() => toChannel(that())))));
|
|
2694
|
-
|
|
2695
|
-
/** @internal */
|
|
2696
|
-
const provideContext = /*#__PURE__*/dual(2, (self, context) => new SinkImpl(pipe(toChannel(self), provideContext$1(context))));
|
|
2697
|
-
|
|
2698
|
-
/** @internal */
|
|
2699
|
-
const race = /*#__PURE__*/dual(2, (self, that) => pipe(self, raceBoth(that), map(merge$2)));
|
|
2700
|
-
|
|
2701
|
-
/** @internal */
|
|
2702
|
-
const raceBoth = /*#__PURE__*/dual(args => isSink(args[1]), (self, that, options) => raceWith(self, {
|
|
2703
|
-
other: that,
|
|
2704
|
-
onSelfDone: selfDone => Done$1(map$2(selfDone, left)),
|
|
2705
|
-
onOtherDone: thatDone => Done$1(map$2(thatDone, right)),
|
|
2706
|
-
capacity: options?.capacity ?? 16
|
|
2707
|
-
}));
|
|
2708
|
-
|
|
2709
|
-
/** @internal */
|
|
2710
|
-
const raceWith = /*#__PURE__*/dual(2, (self, options) => {
|
|
2711
|
-
const scoped = gen(function* ($) {
|
|
2712
|
-
const hub = yield* $(bounded$1(options?.capacity ?? 16));
|
|
2713
|
-
const channel1 = yield* $(fromHubScoped(hub));
|
|
2714
|
-
const channel2 = yield* $(fromHubScoped(hub));
|
|
2715
|
-
const reader = toHub(hub);
|
|
2716
|
-
const writer = pipe(channel1, pipeTo(toChannel(self)), mergeWith({
|
|
2717
|
-
other: pipe(channel2, pipeTo(toChannel(options.other))),
|
|
2718
|
-
onSelfDone: options.onSelfDone,
|
|
2719
|
-
onOtherDone: options.onOtherDone
|
|
2720
|
-
}));
|
|
2721
|
-
const racedChannel = mergeWith(reader, {
|
|
2722
|
-
other: writer,
|
|
2723
|
-
onSelfDone: _ => Await(exit => suspend$2(() => exit)),
|
|
2724
|
-
onOtherDone: done => Done$1(suspend$2(() => done))
|
|
2725
|
-
});
|
|
2726
|
-
return new SinkImpl(racedChannel);
|
|
2727
|
-
});
|
|
2728
|
-
return unwrapScoped(scoped);
|
|
2729
|
-
});
|
|
2730
|
-
|
|
2731
|
-
/** @internal */
|
|
2732
|
-
const refineOrDie = /*#__PURE__*/dual(2, (self, pf) => pipe(self, refineOrDieWith(pf, identity)));
|
|
2733
|
-
|
|
2734
|
-
/** @internal */
|
|
2735
|
-
const refineOrDieWith = /*#__PURE__*/dual(3, (self, pf, f) => {
|
|
2736
|
-
const newChannel = pipe(self, toChannel, catchAll(error => match$2(pf(error), {
|
|
2737
|
-
onNone: () => failCauseSync$1(() => die$2(f(error))),
|
|
2738
|
-
onSome: fail$1
|
|
2739
|
-
})));
|
|
2740
|
-
return new SinkImpl(newChannel);
|
|
2741
|
-
});
|
|
2742
|
-
|
|
2743
|
-
/** @internal */
|
|
2744
|
-
const some = predicate => fold(false, bool => !bool, (acc, input) => acc || predicate(input));
|
|
2745
|
-
|
|
2746
|
-
/** @internal */
|
|
2747
|
-
const splitWhere = /*#__PURE__*/dual(2, (self, f) => {
|
|
2748
|
-
const newChannel = pipe(fromEffect$1(make$1(empty())), flatMap$1(ref => pipe(splitWhereSplitter(false, ref, f), pipeToOrFail(toChannel(self)), collectElements, flatMap$1(([leftovers, z]) => pipe(fromEffect$1(get(ref)), flatMap$1(leftover => pipe(write(pipe(leftover, appendAll(flatten$2(leftovers)))), zipRight$1(succeed$1(z)))))))));
|
|
2749
|
-
return new SinkImpl(newChannel);
|
|
2750
|
-
});
|
|
2751
|
-
|
|
2752
|
-
/** @internal */
|
|
2753
|
-
const splitWhereSplitter = (written, leftovers, f) => readWithCause({
|
|
2754
|
-
onInput: input => {
|
|
2755
|
-
if (isEmpty(input)) {
|
|
2756
|
-
return splitWhereSplitter(written, leftovers, f);
|
|
2757
|
-
}
|
|
2758
|
-
if (written) {
|
|
2759
|
-
const index = indexWhere(input, f);
|
|
2760
|
-
if (index === -1) {
|
|
2761
|
-
return zipRight$1(write(input), splitWhereSplitter(true, leftovers, f));
|
|
2762
|
-
}
|
|
2763
|
-
const [left, right] = splitAt(input, index);
|
|
2764
|
-
return zipRight$1(write(left), fromEffect$1(set(leftovers, right)));
|
|
2765
|
-
}
|
|
2766
|
-
const index = indexWhere(input, f, 1);
|
|
2767
|
-
if (index === -1) {
|
|
2768
|
-
return zipRight$1(write(input), splitWhereSplitter(true, leftovers, f));
|
|
2769
|
-
}
|
|
2770
|
-
const [left, right] = pipe(input, splitAt(Math.max(index, 1)));
|
|
2771
|
-
return zipRight$1(write(left), fromEffect$1(set(leftovers, right)));
|
|
2772
|
-
},
|
|
2773
|
-
onFailure: failCause$1,
|
|
2774
|
-
onDone: succeed$1
|
|
2775
|
-
});
|
|
2776
|
-
|
|
2777
|
-
/** @internal */
|
|
2778
|
-
const indexWhere = (self, predicate, from = 0) => {
|
|
2779
|
-
const iterator = self[Symbol.iterator]();
|
|
2780
|
-
let index = 0;
|
|
2781
|
-
let result = -1;
|
|
2782
|
-
let next;
|
|
2783
|
-
while (result < 0 && (next = iterator.next()) && !next.done) {
|
|
2784
|
-
const a = next.value;
|
|
2785
|
-
if (index >= from && predicate(a)) {
|
|
2786
|
-
result = index;
|
|
2787
|
-
}
|
|
2788
|
-
index = index + 1;
|
|
2789
|
-
}
|
|
2790
|
-
return result;
|
|
2791
|
-
};
|
|
2792
|
-
|
|
2793
|
-
/** @internal */
|
|
2794
|
-
const succeed = z => new SinkImpl(succeed$1(z));
|
|
2795
|
-
|
|
2796
|
-
/** @internal */
|
|
2797
|
-
const sum = /*#__PURE__*/foldLeftChunks(0, (acc, chunk) => acc + reduce(chunk, 0, (s, a) => s + a));
|
|
2798
|
-
|
|
2799
|
-
/** @internal */
|
|
2800
|
-
const summarized = /*#__PURE__*/dual(3, (self, summary, f) => {
|
|
2801
|
-
const newChannel = pipe(fromEffect$1(summary), flatMap$1(start => pipe(self, toChannel, flatMap$1(done => pipe(fromEffect$1(summary), map$1(end => [done, f(start, end)]))))));
|
|
2802
|
-
return new SinkImpl(newChannel);
|
|
2803
|
-
});
|
|
2804
|
-
|
|
2805
|
-
/** @internal */
|
|
2806
|
-
const sync = evaluate => new SinkImpl(sync$1(evaluate));
|
|
2807
|
-
|
|
2808
|
-
/** @internal */
|
|
2809
|
-
const take = n => pipe(foldChunks(empty(), chunk => chunk.length < n, (acc, chunk) => pipe(acc, appendAll(chunk))), flatMap(acc => {
|
|
2810
|
-
const [taken, leftover] = pipe(acc, splitAt(n));
|
|
2811
|
-
return new SinkImpl(pipe(write(leftover), zipRight$1(succeedNow(taken))));
|
|
2812
|
-
}));
|
|
2813
|
-
|
|
2814
|
-
/** @internal */
|
|
2815
|
-
const toChannel = self => isEffect(self) ? toChannel(fromEffect(self)) : self.channel;
|
|
2816
|
-
|
|
2817
|
-
/** @internal */
|
|
2818
|
-
const unwrap = effect => new SinkImpl(unwrap$1(pipe(effect, map$2(sink => toChannel(sink)))));
|
|
2819
|
-
|
|
2820
|
-
/** @internal */
|
|
2821
|
-
const unwrapScoped = effect => {
|
|
2822
|
-
return new SinkImpl(unwrapScoped$1(pipe(effect, map$2(sink => toChannel(sink)))));
|
|
2823
|
-
};
|
|
2824
|
-
|
|
2825
|
-
/** @internal */
|
|
2826
|
-
const withDuration = self => pipe(self, summarized(currentTimeMillis, (start, end) => millis(end - start)));
|
|
2827
|
-
|
|
2828
|
-
/** @internal */
|
|
2829
|
-
const zip = /*#__PURE__*/dual(args => isSink(args[1]), (self, that, options) => zipWith(self, that, (z, z2) => [z, z2], options));
|
|
2830
|
-
|
|
2831
|
-
/** @internal */
|
|
2832
|
-
const zipLeft = /*#__PURE__*/dual(args => isSink(args[1]), (self, that, options) => zipWith(self, that, (z, _) => z, options));
|
|
2833
|
-
|
|
2834
|
-
/** @internal */
|
|
2835
|
-
const zipRight = /*#__PURE__*/dual(args => isSink(args[1]), (self, that, options) => zipWith(self, that, (_, z2) => z2, options));
|
|
2836
|
-
|
|
2837
|
-
/** @internal */
|
|
2838
|
-
const zipWith = /*#__PURE__*/dual(args => isSink(args[1]), (self, that, f, options) => options?.concurrent ? raceWith(self, {
|
|
2839
|
-
other: that,
|
|
2840
|
-
onSelfDone: match$1({
|
|
2841
|
-
onFailure: cause => Done$1(failCause$3(cause)),
|
|
2842
|
-
onSuccess: leftZ => Await(match$1({
|
|
2843
|
-
onFailure: failCause$3,
|
|
2844
|
-
onSuccess: rightZ => succeed$3(f(leftZ, rightZ))
|
|
2845
|
-
}))
|
|
2846
|
-
}),
|
|
2847
|
-
onOtherDone: match$1({
|
|
2848
|
-
onFailure: cause => Done$1(failCause$3(cause)),
|
|
2849
|
-
onSuccess: rightZ => Await(match$1({
|
|
2850
|
-
onFailure: failCause$3,
|
|
2851
|
-
onSuccess: leftZ => succeed$3(f(leftZ, rightZ))
|
|
2852
|
-
}))
|
|
2853
|
-
})
|
|
2854
|
-
}) : flatMap(self, z => map(that, z2 => f(z, z2))));
|
|
2855
|
-
|
|
2856
|
-
// Circular with Channel
|
|
2857
|
-
|
|
2858
|
-
/** @internal */
|
|
2859
|
-
const channelToSink = self => new SinkImpl(self);
|
|
2860
|
-
|
|
2861
|
-
// Constants
|
|
2862
|
-
|
|
2863
|
-
/** @internal */
|
|
2864
|
-
const count = /*#__PURE__*/foldLeftChunks(0, (acc, chunk) => acc + chunk.length);
|
|
2865
|
-
|
|
2866
|
-
/** @internal */
|
|
2867
|
-
const mkString = /*#__PURE__*/suspend(() => {
|
|
2868
|
-
const strings = [];
|
|
2869
|
-
return pipe(foldLeftChunks(void 0, (_, elems) => map$5(elems, elem => {
|
|
2870
|
-
strings.push(String(elem));
|
|
2871
|
-
})), map(() => strings.join("")));
|
|
2872
|
-
});
|
|
2873
|
-
|
|
2874
|
-
/** @internal */
|
|
2875
|
-
const timed = /*#__PURE__*/pipe( /*#__PURE__*/withDuration(drain), /*#__PURE__*/map(tuple => tuple[1]));
|
|
2876
|
-
|
|
2877
|
-
export { drain as $, succeed$1 as A, mapOut as B, ChannelTypeId as C, mapOutEffectPar as D, repeated as E, collectAllN as F, interruptWhen as G, interruptWhenDeferred as H, mapOutEffect as I, mapError$1 as J, mapErrorCause as K, mergeWith as L, mkString as M, orDieWith as N, orElse$1 as O, foldSink as P, collectLeftover as Q, zipRight as R, SinkTypeId as S, fromEffect as T, fail as U, fromChannel as V, provideContext$1 as W, catchAll as X, runDrain as Y, collectAll as Z, count as _, readWithCause as a, foldUntilEffect as a$, fold as a0, foldEffect as a1, forEach as a2, forEachChunk as a3, forEachWhile as a4, head as a5, last as a6, sum as a7, scoped as a8, foldCauseChannel as a9, dimapChunks as aA, dimapChunksEffect as aB, drop as aC, dropUntil as aD, dropUntilEffect as aE, dropWhile as aF, dropWhileEffect as aG, ensuring as aH, ensuringWith as aI, context as aJ, contextWith as aK, contextWithEffect as aL, contextWithSink as aM, every as aN, failSync as aO, failCause as aP, failCauseSync as aQ, filterInput as aR, filterInputEffect as aS, findEffect as aT, foldChunks as aU, foldChunksEffect as aV, foldLeft as aW, foldLeftChunks as aX, foldLeftChunksEffect as aY, foldLeftEffect as aZ, foldUntil as a_, toPull as aa, fromInput as ab, embedInput as ac, mergeMap as ad, sync$1 as ae, writeAll as af, as as ag, collectAllFrom as ah, collectAllToMap as ai, collectAllToMapN as aj, collectAllToSet as ak, collectAllToSetN as al, collectAllUntil as am, collectAllUntilEffect as an, collectAllWhile as ao, collectAllWhileEffect as ap, collectAllWhileWith as aq, mapInput as ar, mapInputEffect as as, mapInputChunks as at, mapInputChunksEffect as au, die as av, dieMessage as aw, dieSync as ax, dimap as ay, dimapEffect as az, fromEffect$1 as b, failCauseSync$1 as b$, foldWeighted as b0, foldWeightedDecompose as b1, foldWeightedDecomposeEffect as b2, foldWeightedEffect as b3, forEachChunkWhile as b4, flatMap as b5, fromHub as b6, fromPush as b7, fromQueue as b8, ignoreLeftover as b9, zipWith as bA, ChannelExceptionTypeId as bB, acquireUseRelease as bC, acquireReleaseOut as bD, as$1 as bE, asUnit as bF, buffer as bG, bufferChunk as bH, concatAll as bI, concatAllWith as bJ, concatMapWith as bK, concatMapWithCustom as bL, collect as bM, concatOut as bN, mapInput$1 as bO, mapInputEffect$1 as bP, mapInputError as bQ, mapInputErrorEffect as bR, mapInputIn as bS, mapInputInEffect as bT, doneCollect as bU, emitCollect as bV, context$1 as bW, contextWith$1 as bX, contextWithChannel as bY, contextWithEffect$1 as bZ, failSync$1 as b_, leftover as ba, map as bb, mapEffect as bc, mapError as bd, mapLeftover as be, never as bf, orElse as bg, provideContext as bh, race as bi, raceBoth as bj, raceWith as bk, refineOrDie as bl, refineOrDieWith as bm, some as bn, splitWhere as bo, succeed as bp, summarized as bq, suspend as br, sync as bs, take as bt, timed as bu, unwrap as bv, unwrapScoped as bw, withDuration as bx, zip as by, zipLeft as bz, failCause$1 as c, flatten as c0, foldChannel as c1, fromEither as c2, fromHub$1 as c3, fromHubScoped as c4, fromOption as c5, fromQueue$1 as c6, map$1 as c7, mapEffect$1 as c8, mergeAll as c9, mergeAllUnbounded as ca, mergeAllUnboundedWith as cb, mergeAllWith as cc, mergeOut as cd, mergeOutWith as ce, never$1 as cf, orDie as cg, provideLayer as ch, mapInputContext as ci, provideSomeLayer as cj, provideService as ck, read as cl, readOrFail as cm, run as cn, runCollect as co, toHub as cp, toQueue as cq, channelToSink as cr, updateService as cs, withSpan as ct, zip$1 as cu, zipLeft$1 as cv, ChannelException as cw, isChannelException as cx, drain$1 as d, unit as e, flatMap$1 as f, run$1 as g, pipeToOrFail as h, collectElements as i, unwrapScoped$1 as j, fail$1 as k, catchAllCause as l, concatMap as m, writeChunk as n, readWith as o, pipeTo as p, identityChannel as q, runScoped as r, suspend$1 as s, toChannel as t, unwrap$1 as u, succeedNow as v, write as w, ensuring$1 as x, ensuringWith$1 as y, zipRight$1 as z };
|