effect 2.0.0-next.46 → 2.0.0-next.48
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.d.mts +2 -0
- package/BigInt/dist/effect-BigInt.cjs.d.mts.map +1 -0
- package/BigInt/dist/effect-BigInt.cjs.d.ts +2 -0
- package/BigInt/dist/effect-BigInt.cjs.d.ts.map +1 -0
- package/{Bigint/dist/effect-Bigint.cjs.dev.js → BigInt/dist/effect-BigInt.cjs.dev.js} +30 -30
- package/BigInt/dist/effect-BigInt.cjs.js +7 -0
- package/{Bigint/dist/effect-Bigint.cjs.mjs → BigInt/dist/effect-BigInt.cjs.mjs} +2 -2
- package/{Bigint/dist/effect-Bigint.cjs.prod.js → BigInt/dist/effect-BigInt.cjs.prod.js} +30 -30
- package/{Bigint/dist/effect-Bigint.esm.js → BigInt/dist/effect-BigInt.esm.js} +28 -28
- package/BigInt/package.json +4 -0
- package/Brand/dist/effect-Brand.cjs.dev.js +3 -3
- package/Brand/dist/effect-Brand.cjs.prod.js +3 -3
- package/Cache/dist/effect-Cache.cjs.dev.js +28 -28
- package/Cache/dist/effect-Cache.cjs.prod.js +28 -28
- package/Cause/dist/effect-Cause.cjs.dev.js +8 -8
- package/Cause/dist/effect-Cause.cjs.prod.js +8 -8
- package/Channel/dist/effect-Channel.cjs.dev.js +41 -41
- package/Channel/dist/effect-Channel.cjs.prod.js +41 -41
- package/ChannelSingleProducerAsyncInput/dist/effect-ChannelSingleProducerAsyncInput.cjs.dev.js +36 -38
- package/ChannelSingleProducerAsyncInput/dist/effect-ChannelSingleProducerAsyncInput.cjs.prod.js +36 -38
- package/Chunk/dist/effect-Chunk.cjs.dev.js +3 -3
- package/Chunk/dist/effect-Chunk.cjs.prod.js +3 -3
- package/Clock/dist/effect-Clock.cjs.dev.js +14 -14
- package/Clock/dist/effect-Clock.cjs.prod.js +14 -14
- package/Config/dist/effect-Config.cjs.dev.js +11 -11
- package/Config/dist/effect-Config.cjs.prod.js +11 -11
- package/ConfigError/dist/effect-ConfigError.cjs.dev.js +4 -4
- package/ConfigError/dist/effect-ConfigError.cjs.prod.js +4 -4
- package/ConfigProvider/dist/effect-ConfigProvider.cjs.dev.js +13 -13
- package/ConfigProvider/dist/effect-ConfigProvider.cjs.prod.js +13 -13
- package/ConfigProviderPathPatch/dist/effect-ConfigProviderPathPatch.cjs.dev.js +5 -5
- package/ConfigProviderPathPatch/dist/effect-ConfigProviderPathPatch.cjs.prod.js +5 -5
- package/ConfigSecret/dist/effect-ConfigSecret.cjs.dev.js +4 -4
- package/ConfigSecret/dist/effect-ConfigSecret.cjs.prod.js +4 -4
- package/Console/dist/effect-Console.cjs.dev.js +32 -32
- package/Console/dist/effect-Console.cjs.prod.js +32 -32
- package/Context/dist/effect-Context.cjs.dev.js +3 -3
- package/Context/dist/effect-Context.cjs.prod.js +3 -3
- package/Data/dist/effect-Data.cjs.dev.js +50 -46
- package/Data/dist/effect-Data.cjs.prod.js +50 -46
- package/Data/dist/effect-Data.esm.js +11 -5
- package/DefaultServices/dist/effect-DefaultServices.cjs.dev.js +14 -14
- package/DefaultServices/dist/effect-DefaultServices.cjs.prod.js +14 -14
- package/Deferred/dist/effect-Deferred.cjs.dev.js +8 -8
- package/Deferred/dist/effect-Deferred.cjs.prod.js +8 -8
- package/Differ/dist/effect-Differ.cjs.dev.js +5 -5
- package/Differ/dist/effect-Differ.cjs.prod.js +5 -5
- package/Duration/dist/effect-Duration.cjs.dev.js +4 -4
- package/Duration/dist/effect-Duration.cjs.prod.js +4 -4
- package/Duration/dist/effect-Duration.esm.js +2 -2
- package/Effect/dist/effect-Effect.cjs.dev.js +67 -136
- package/Effect/dist/effect-Effect.cjs.mjs +2 -11
- package/Effect/dist/effect-Effect.cjs.prod.js +67 -136
- package/Effect/dist/effect-Effect.esm.js +30 -90
- package/Effectable/dist/effect-Effectable.cjs.dev.js +1 -1
- package/Effectable/dist/effect-Effectable.cjs.prod.js +1 -1
- package/Either/dist/effect-Either.cjs.dev.js +17 -3
- package/Either/dist/effect-Either.cjs.mjs +3 -1
- package/Either/dist/effect-Either.cjs.prod.js +17 -3
- package/Either/dist/effect-Either.esm.js +13 -1
- package/Encoding/dist/effect-Encoding.cjs.dev.js +3 -3
- package/Encoding/dist/effect-Encoding.cjs.prod.js +3 -3
- package/Exit/dist/effect-Exit.cjs.dev.js +8 -8
- package/Exit/dist/effect-Exit.cjs.prod.js +8 -8
- package/Fiber/dist/effect-Fiber.cjs.dev.js +29 -29
- package/Fiber/dist/effect-Fiber.cjs.prod.js +29 -29
- package/FiberId/dist/effect-FiberId.cjs.dev.js +5 -5
- package/FiberId/dist/effect-FiberId.cjs.prod.js +5 -5
- package/FiberRef/dist/effect-FiberRef.cjs.dev.js +29 -29
- package/FiberRef/dist/effect-FiberRef.cjs.prod.js +29 -29
- package/FiberRefs/dist/effect-FiberRefs.cjs.dev.js +9 -9
- package/FiberRefs/dist/effect-FiberRefs.cjs.prod.js +9 -9
- package/FiberRefsPatch/dist/effect-FiberRefsPatch.cjs.dev.js +10 -10
- package/FiberRefsPatch/dist/effect-FiberRefsPatch.cjs.prod.js +10 -10
- package/GroupBy/dist/effect-GroupBy.cjs.dev.js +43 -43
- package/GroupBy/dist/effect-GroupBy.cjs.prod.js +43 -43
- package/HashMap/dist/effect-HashMap.cjs.dev.js +4 -4
- package/HashMap/dist/effect-HashMap.cjs.prod.js +4 -4
- package/HashSet/dist/effect-HashSet.cjs.dev.js +4 -4
- package/HashSet/dist/effect-HashSet.cjs.prod.js +4 -4
- package/KeyedPool/dist/effect-KeyedPool.cjs.dev.js +29 -29
- package/KeyedPool/dist/effect-KeyedPool.cjs.prod.js +29 -29
- package/Layer/dist/effect-Layer.cjs.dev.js +151 -52
- package/Layer/dist/effect-Layer.cjs.mjs +12 -0
- package/Layer/dist/effect-Layer.cjs.prod.js +151 -52
- package/Layer/dist/effect-Layer.esm.js +92 -2
- package/List/dist/effect-List.cjs.dev.js +3 -3
- package/List/dist/effect-List.cjs.prod.js +3 -3
- package/LogLevel/dist/effect-LogLevel.cjs.dev.js +8 -8
- package/LogLevel/dist/effect-LogLevel.cjs.prod.js +8 -8
- package/Logger/dist/effect-Logger.cjs.dev.js +33 -39
- package/Logger/dist/effect-Logger.cjs.prod.js +33 -39
- package/Logger/dist/effect-Logger.esm.js +0 -5
- package/Match/dist/effect-Match.cjs.d.mts +2 -0
- package/Match/dist/effect-Match.cjs.d.mts.map +1 -0
- package/Match/dist/effect-Match.cjs.d.ts +2 -0
- package/Match/dist/effect-Match.cjs.d.ts.map +1 -0
- package/Match/dist/effect-Match.cjs.dev.js +620 -0
- package/Match/dist/effect-Match.cjs.js +7 -0
- package/Match/dist/effect-Match.cjs.mjs +39 -0
- package/Match/dist/effect-Match.cjs.prod.js +620 -0
- package/Match/dist/effect-Match.esm.js +258 -0
- package/Match/package.json +4 -0
- package/Metric/dist/effect-Metric.cjs.dev.js +27 -27
- package/Metric/dist/effect-Metric.cjs.prod.js +27 -27
- package/MetricBoundaries/dist/effect-MetricBoundaries.cjs.dev.js +4 -4
- package/MetricBoundaries/dist/effect-MetricBoundaries.cjs.prod.js +4 -4
- package/MetricHook/dist/effect-MetricHook.cjs.dev.js +6 -6
- package/MetricHook/dist/effect-MetricHook.cjs.prod.js +6 -6
- package/MetricKey/dist/effect-MetricKey.cjs.dev.js +7 -7
- package/MetricKey/dist/effect-MetricKey.cjs.prod.js +7 -7
- package/MetricKeyType/dist/effect-MetricKeyType.cjs.dev.js +4 -4
- package/MetricKeyType/dist/effect-MetricKeyType.cjs.prod.js +4 -4
- package/MetricLabel/dist/effect-MetricLabel.cjs.dev.js +1 -1
- package/MetricLabel/dist/effect-MetricLabel.cjs.prod.js +1 -1
- package/MetricPolling/dist/effect-MetricPolling.cjs.dev.js +29 -29
- package/MetricPolling/dist/effect-MetricPolling.cjs.prod.js +29 -29
- package/MetricRegistry/dist/effect-MetricRegistry.cjs.dev.js +8 -8
- package/MetricRegistry/dist/effect-MetricRegistry.cjs.prod.js +8 -8
- package/MetricState/dist/effect-MetricState.cjs.dev.js +1 -1
- package/MetricState/dist/effect-MetricState.cjs.prod.js +1 -1
- package/MutableHashMap/dist/effect-MutableHashMap.cjs.dev.js +4 -4
- package/MutableHashMap/dist/effect-MutableHashMap.cjs.prod.js +4 -4
- package/MutableHashSet/dist/effect-MutableHashSet.cjs.dev.js +4 -4
- package/MutableHashSet/dist/effect-MutableHashSet.cjs.prod.js +4 -4
- package/MutableQueue/dist/effect-MutableQueue.cjs.dev.js +3 -3
- package/MutableQueue/dist/effect-MutableQueue.cjs.prod.js +3 -3
- package/Option/dist/effect-Option.cjs.dev.js +3 -3
- package/Option/dist/effect-Option.cjs.prod.js +3 -3
- package/Pool/dist/effect-Pool.cjs.dev.js +29 -29
- package/Pool/dist/effect-Pool.cjs.prod.js +29 -29
- package/Predicate/dist/effect-Predicate.cjs.dev.js +5 -5
- package/Predicate/dist/effect-Predicate.cjs.mjs +1 -1
- package/Predicate/dist/effect-Predicate.cjs.prod.js +5 -5
- package/Predicate/dist/effect-Predicate.esm.js +5 -5
- package/PubSub/dist/effect-PubSub.cjs.dev.js +28 -28
- package/PubSub/dist/effect-PubSub.cjs.prod.js +28 -28
- package/Queue/dist/effect-Queue.cjs.dev.js +28 -28
- package/Queue/dist/effect-Queue.cjs.prod.js +28 -28
- package/README.md +23 -0
- package/Random/dist/effect-Random.cjs.dev.js +14 -14
- package/Random/dist/effect-Random.cjs.prod.js +14 -14
- package/ReadonlyArray/dist/effect-ReadonlyArray.cjs.dev.js +3 -3
- package/ReadonlyArray/dist/effect-ReadonlyArray.cjs.prod.js +3 -3
- package/ReadonlyRecord/dist/effect-ReadonlyRecord.cjs.dev.js +3 -3
- package/ReadonlyRecord/dist/effect-ReadonlyRecord.cjs.prod.js +3 -3
- package/RedBlackTree/dist/effect-RedBlackTree.cjs.dev.js +3 -3
- package/RedBlackTree/dist/effect-RedBlackTree.cjs.prod.js +3 -3
- package/Ref/dist/effect-Ref.cjs.dev.js +9 -9
- package/Ref/dist/effect-Ref.cjs.prod.js +9 -9
- package/Reloadable/dist/effect-Reloadable.cjs.dev.js +33 -33
- package/Reloadable/dist/effect-Reloadable.cjs.prod.js +33 -33
- package/Request/dist/effect-Request.cjs.dev.js +28 -28
- package/Request/dist/effect-Request.cjs.prod.js +28 -28
- package/RequestBlock/dist/effect-RequestBlock.cjs.dev.js +36 -38
- package/RequestBlock/dist/effect-RequestBlock.cjs.prod.js +36 -38
- package/RequestResolver/dist/effect-RequestResolver.cjs.dev.js +42 -44
- package/RequestResolver/dist/effect-RequestResolver.cjs.prod.js +42 -44
- package/Resource/dist/effect-Resource.cjs.dev.js +31 -31
- package/Resource/dist/effect-Resource.cjs.prod.js +31 -31
- package/Runtime/dist/effect-Runtime.cjs.dev.js +30 -30
- package/Runtime/dist/effect-Runtime.cjs.prod.js +30 -30
- package/RuntimeFlags/dist/effect-RuntimeFlags.cjs.dev.js +33 -34
- package/RuntimeFlags/dist/effect-RuntimeFlags.cjs.prod.js +33 -34
- package/RuntimeFlagsPatch/dist/effect-RuntimeFlagsPatch.cjs.dev.js +6 -6
- package/RuntimeFlagsPatch/dist/effect-RuntimeFlagsPatch.cjs.prod.js +6 -6
- package/STM/dist/effect-STM.cjs.dev.js +45 -45
- package/STM/dist/effect-STM.cjs.prod.js +45 -45
- package/Schedule/dist/effect-Schedule.cjs.dev.js +20 -20
- package/Schedule/dist/effect-Schedule.cjs.prod.js +20 -20
- package/ScheduleDecision/dist/effect-ScheduleDecision.cjs.dev.js +3 -3
- package/ScheduleDecision/dist/effect-ScheduleDecision.cjs.prod.js +3 -3
- package/ScheduleInterval/dist/effect-ScheduleInterval.cjs.dev.js +3 -3
- package/ScheduleInterval/dist/effect-ScheduleInterval.cjs.prod.js +3 -3
- package/ScheduleIntervals/dist/effect-ScheduleIntervals.cjs.dev.js +3 -3
- package/ScheduleIntervals/dist/effect-ScheduleIntervals.cjs.prod.js +3 -3
- package/Scheduler/dist/effect-Scheduler.cjs.dev.js +8 -8
- package/Scheduler/dist/effect-Scheduler.cjs.prod.js +8 -8
- package/Scope/dist/effect-Scope.cjs.dev.js +27 -27
- package/Scope/dist/effect-Scope.cjs.prod.js +27 -27
- package/ScopedCache/dist/effect-ScopedCache.cjs.dev.js +34 -36
- package/ScopedCache/dist/effect-ScopedCache.cjs.prod.js +34 -36
- package/ScopedRef/dist/effect-ScopedRef.cjs.dev.js +31 -31
- package/ScopedRef/dist/effect-ScopedRef.cjs.prod.js +31 -31
- package/Sink/dist/effect-Sink.cjs.dev.js +39 -39
- package/Sink/dist/effect-Sink.cjs.prod.js +39 -39
- package/SortedMap/dist/effect-SortedMap.cjs.dev.js +3 -3
- package/SortedMap/dist/effect-SortedMap.cjs.prod.js +3 -3
- package/SortedSet/dist/effect-SortedSet.cjs.dev.js +3 -3
- package/SortedSet/dist/effect-SortedSet.cjs.prod.js +3 -3
- package/Stream/dist/effect-Stream.cjs.dev.js +43 -43
- package/Stream/dist/effect-Stream.cjs.prod.js +43 -43
- package/Streamable/dist/effect-Streamable.cjs.dev.js +43 -43
- package/Streamable/dist/effect-Streamable.cjs.prod.js +43 -43
- package/String/dist/effect-String.cjs.dev.js +3 -3
- package/String/dist/effect-String.cjs.prod.js +3 -3
- package/SubscriptionRef/dist/effect-SubscriptionRef.cjs.dev.js +46 -46
- package/SubscriptionRef/dist/effect-SubscriptionRef.cjs.prod.js +46 -46
- package/Supervisor/dist/effect-Supervisor.cjs.dev.js +33 -34
- package/Supervisor/dist/effect-Supervisor.cjs.prod.js +33 -34
- package/SynchronizedRef/dist/effect-SynchronizedRef.cjs.dev.js +30 -30
- package/SynchronizedRef/dist/effect-SynchronizedRef.cjs.prod.js +30 -30
- package/TArray/dist/effect-TArray.cjs.dev.js +47 -47
- package/TArray/dist/effect-TArray.cjs.prod.js +47 -47
- package/TDeferred/dist/effect-TDeferred.cjs.dev.js +46 -46
- package/TDeferred/dist/effect-TDeferred.cjs.prod.js +46 -46
- package/TMap/dist/effect-TMap.cjs.dev.js +48 -48
- package/TMap/dist/effect-TMap.cjs.prod.js +48 -48
- package/TPriorityQueue/dist/effect-TPriorityQueue.cjs.dev.js +45 -45
- package/TPriorityQueue/dist/effect-TPriorityQueue.cjs.prod.js +45 -45
- package/TPubSub/dist/effect-TPubSub.cjs.dev.js +50 -50
- package/TPubSub/dist/effect-TPubSub.cjs.prod.js +50 -50
- package/TQueue/dist/effect-TQueue.cjs.dev.js +47 -47
- package/TQueue/dist/effect-TQueue.cjs.prod.js +47 -47
- package/TRandom/dist/effect-TRandom.cjs.dev.js +46 -46
- package/TRandom/dist/effect-TRandom.cjs.prod.js +46 -46
- package/TReentrantLock/dist/effect-TReentrantLock.cjs.dev.js +50 -50
- package/TReentrantLock/dist/effect-TReentrantLock.cjs.prod.js +50 -50
- package/TRef/dist/effect-TRef.cjs.dev.js +45 -45
- package/TRef/dist/effect-TRef.cjs.prod.js +45 -45
- package/TSemaphore/dist/effect-TSemaphore.cjs.dev.js +46 -46
- package/TSemaphore/dist/effect-TSemaphore.cjs.prod.js +46 -46
- package/TSet/dist/effect-TSet.cjs.dev.js +48 -48
- package/TSet/dist/effect-TSet.cjs.prod.js +48 -48
- package/Take/dist/effect-Take.cjs.dev.js +36 -38
- package/Take/dist/effect-Take.cjs.prod.js +36 -38
- package/TestAnnotation/dist/effect-TestAnnotation.cjs.dev.js +5 -5
- package/TestAnnotation/dist/effect-TestAnnotation.cjs.prod.js +5 -5
- package/TestAnnotations/dist/effect-TestAnnotations.cjs.dev.js +20 -20
- package/TestAnnotations/dist/effect-TestAnnotations.cjs.prod.js +20 -20
- package/TestClock/dist/effect-TestClock.cjs.dev.js +32 -32
- package/TestClock/dist/effect-TestClock.cjs.prod.js +32 -32
- package/TestConfig/dist/effect-TestConfig.cjs.dev.js +3 -3
- package/TestConfig/dist/effect-TestConfig.cjs.prod.js +3 -3
- package/TestContext/dist/effect-TestContext.cjs.dev.js +34 -36
- package/TestContext/dist/effect-TestContext.cjs.prod.js +34 -36
- package/TestLive/dist/effect-TestLive.cjs.dev.js +14 -14
- package/TestLive/dist/effect-TestLive.cjs.prod.js +14 -14
- package/TestServices/dist/effect-TestServices.cjs.dev.js +40 -42
- package/TestServices/dist/effect-TestServices.cjs.prod.js +40 -42
- package/TestSized/dist/effect-TestSized.cjs.dev.js +8 -8
- package/TestSized/dist/effect-TestSized.cjs.prod.js +8 -8
- package/Tracer/dist/effect-Tracer.cjs.dev.js +20 -18
- package/Tracer/dist/effect-Tracer.cjs.mjs +1 -0
- package/Tracer/dist/effect-Tracer.cjs.prod.js +20 -18
- package/Tracer/dist/effect-Tracer.esm.js +7 -6
- package/dist/{Context-da73ddfa.cjs.dev.js → Context-607e9b4c.cjs.dev.js} +2 -2
- package/dist/{Context-9fe5eb16.cjs.prod.js → Context-c91d8ca0.cjs.prod.js} +2 -2
- package/dist/{Either-d43f082c.cjs.prod.js → Either-a3f96c60.cjs.prod.js} +2 -2
- package/dist/{Either-fa0ef1d9.cjs.dev.js → Either-e7500e90.cjs.dev.js} +2 -2
- package/dist/{Option-463b42e6.cjs.dev.js → Option-01caa9d4.cjs.dev.js} +1 -1
- package/dist/{Option-935e5d7c.cjs.prod.js → Option-dd52e82a.cjs.prod.js} +1 -1
- package/dist/{Ref-acdee7ef.cjs.dev.js → Ref-548003d1.cjs.dev.js} +1 -1
- package/dist/{Ref-4014b526.cjs.prod.js → Ref-6608e3b6.cjs.prod.js} +1 -1
- package/dist/{cache-7eed9d33.cjs.dev.js → cache-7953c9ae.cjs.dev.js} +5 -5
- package/dist/{cache-5c7d77e4.cjs.prod.js → cache-d7096ab5.cjs.prod.js} +5 -5
- package/dist/{circular-c8b65bdb.cjs.dev.js → circular-171d6971.cjs.dev.js} +8 -9
- package/dist/{circular-c2dbce1a.cjs.dev.js → circular-8568ddf2.cjs.dev.js} +7 -7
- package/dist/{circular-1f481ffb.cjs.prod.js → circular-894f44de.cjs.prod.js} +7 -7
- package/dist/{circular-9e10a5a7.cjs.prod.js → circular-b6cc8a1d.cjs.prod.js} +8 -9
- package/dist/{config-5ba54da1.cjs.prod.js → config-615bcaef.cjs.prod.js} +3 -3
- package/dist/{config-3b7935a3.cjs.dev.js → config-ea74e7d0.cjs.dev.js} +3 -3
- package/dist/{configProvider-f34a82f1.cjs.dev.js → configProvider-089a1159.cjs.dev.js} +4 -4
- package/dist/{configProvider-b6b20998.cjs.prod.js → configProvider-3877a6ec.cjs.prod.js} +4 -4
- package/dist/{core-b7401357.cjs.dev.js → core-365f89c2.cjs.dev.js} +3 -3
- package/dist/{core-07202cc0.cjs.prod.js → core-3908bc43.cjs.prod.js} +3 -3
- package/dist/{core-c5747f88.cjs.dev.js → core-3d37486a.cjs.dev.js} +3 -3
- package/dist/{core-7411d1e1.cjs.prod.js → core-8ccae4e2.cjs.prod.js} +3 -3
- package/dist/{core-effect-9201ea63.cjs.prod.js → core-effect-37a0d753.cjs.prod.js} +8 -8
- package/dist/{core-effect-1c564d42.cjs.dev.js → core-effect-c529ccac.cjs.dev.js} +8 -8
- package/dist/{dataSource-b83bc277.cjs.prod.js → dataSource-0e407d86.cjs.prod.js} +2 -2
- package/dist/{dataSource-b5eda714.cjs.dev.js → dataSource-d125d7af.cjs.dev.js} +2 -2
- package/dist/declarations/src/{Bigint.d.ts → BigInt.d.ts} +27 -27
- package/dist/declarations/src/{Bigint.d.ts.map → BigInt.d.ts.map} +1 -1
- package/dist/declarations/src/Channel.d.ts +4 -2
- package/dist/declarations/src/Channel.d.ts.map +1 -1
- package/dist/declarations/src/Data.d.ts +1 -2
- package/dist/declarations/src/Data.d.ts.map +1 -1
- package/dist/declarations/src/Effect.d.ts +67 -102
- package/dist/declarations/src/Effect.d.ts.map +1 -1
- package/dist/declarations/src/Either.d.ts +16 -0
- package/dist/declarations/src/Either.d.ts.map +1 -1
- package/dist/declarations/src/FiberRef.d.ts +2 -2
- package/dist/declarations/src/FiberRef.d.ts.map +1 -1
- package/dist/declarations/src/Layer.d.ts +98 -3
- package/dist/declarations/src/Layer.d.ts.map +1 -1
- package/dist/declarations/src/Logger.d.ts +2 -7
- package/dist/declarations/src/Logger.d.ts.map +1 -1
- package/dist/declarations/src/Match.d.ts +420 -0
- package/dist/declarations/src/Match.d.ts.map +1 -0
- package/dist/declarations/src/Predicate.d.ts +4 -4
- package/dist/declarations/src/Queue.d.ts +5 -0
- package/dist/declarations/src/Queue.d.ts.map +1 -1
- package/dist/declarations/src/Stream.d.ts +4 -2
- package/dist/declarations/src/Stream.d.ts.map +1 -1
- package/dist/declarations/src/Tracer.d.ts +17 -10
- package/dist/declarations/src/Tracer.d.ts.map +1 -1
- package/dist/declarations/src/index.d.ts +5 -1
- package/dist/declarations/src/index.d.ts.map +1 -1
- package/dist/{defaultServices-9d7ce86f.cjs.prod.js → defaultServices-1c3db777.cjs.prod.js} +15 -4
- package/dist/{defaultServices-755d5b46.cjs.dev.js → defaultServices-a933c201.cjs.dev.js} +15 -4
- package/dist/effect.cjs.dev.js +6 -3
- package/dist/effect.cjs.mjs +2 -1
- package/dist/effect.cjs.prod.js +6 -3
- package/dist/effect.esm.js +4 -2
- package/dist/{fiber-5156eff2.cjs.dev.js → fiber-13587a5a.cjs.dev.js} +3 -3
- package/dist/{fiber-9519d109.cjs.prod.js → fiber-2858bd1f.cjs.prod.js} +3 -3
- package/dist/{fiberRefs-98b71233.cjs.dev.js → fiberRefs-abe2a811.cjs.dev.js} +1 -1
- package/dist/{fiberRefs-558c17e6.cjs.prod.js → fiberRefs-ea1edd57.cjs.prod.js} +1 -1
- package/dist/{fiberRuntime-31ae011f.cjs.prod.js → fiberRuntime-9fafeaab.cjs.prod.js} +27 -23
- package/dist/{fiberRuntime-d3872282.cjs.dev.js → fiberRuntime-ebcb168f.cjs.dev.js} +27 -23
- package/dist/{groupBy-862cc2da.cjs.dev.js → groupBy-050e6b17.cjs.dev.js} +4 -4
- package/dist/{groupBy-724f64ef.cjs.prod.js → groupBy-93f35a1d.cjs.prod.js} +4 -4
- package/dist/{hook-8cefc909.cjs.dev.js → hook-2c94278c.cjs.dev.js} +1 -1
- package/dist/{hook-98ce30e4.cjs.prod.js → hook-9af5cf52.cjs.prod.js} +1 -1
- package/dist/{key-198b6670.cjs.dev.js → key-2d4efb00.cjs.dev.js} +2 -2
- package/dist/{key-eb8a12b2.cjs.prod.js → key-9b2f3322.cjs.prod.js} +2 -2
- package/dist/{layer-29574350.cjs.dev.js → layer-09807eda.cjs.dev.js} +15 -10
- package/dist/{layer-51ff4846.cjs.prod.js → layer-fc5b5ca7.cjs.prod.js} +15 -10
- package/dist/{patch-0220a642.cjs.dev.js → patch-2f545954.cjs.dev.js} +1 -1
- package/dist/{patch-7c559bb2.cjs.prod.js → patch-e72c6c2f.cjs.prod.js} +1 -1
- package/dist/{pathPatch-fab016f1.cjs.dev.js → pathPatch-9fa78980.cjs.dev.js} +1 -1
- package/dist/{pathPatch-b56a4da2.cjs.prod.js → pathPatch-f3064fa9.cjs.prod.js} +1 -1
- package/dist/{pool-3211287f.cjs.dev.js → pool-7c9cd8e9.cjs.dev.js} +5 -5
- package/dist/{pool-f77d7705.cjs.prod.js → pool-9370f703.cjs.prod.js} +5 -5
- package/dist/{query-c36decd5.cjs.dev.js → query-6cd164ab.cjs.dev.js} +3 -3
- package/dist/{query-a52b25f0.cjs.prod.js → query-8147932f.cjs.prod.js} +3 -3
- package/dist/{queue-7a223c44.cjs.dev.js → queue-06ce789d.cjs.dev.js} +23 -13
- package/dist/{queue-315ea45d.cjs.prod.js → queue-6afe5f19.cjs.prod.js} +23 -13
- package/dist/{registry-62ff192e.cjs.dev.js → registry-35e8eb48.cjs.dev.js} +2 -2
- package/dist/{registry-d5258dff.cjs.prod.js → registry-5c67df33.cjs.prod.js} +2 -2
- package/dist/{runtime-005f8a9b.cjs.prod.js → runtime-d41d839b.cjs.prod.js} +6 -6
- package/dist/{runtime-57c8ddf8.cjs.dev.js → runtime-fb1c1c19.cjs.dev.js} +6 -6
- package/dist/{schedule-e7a9f93f.cjs.dev.js → schedule-0e1db444.cjs.dev.js} +3 -3
- package/dist/{schedule-8cdf6bf1.cjs.prod.js → schedule-64057679.cjs.prod.js} +3 -3
- package/dist/{scopedRef-eb19c7a6.cjs.dev.js → scopedRef-2ea09a4f.cjs.dev.js} +6 -6
- package/dist/{scopedRef-789d7fef.cjs.prod.js → scopedRef-7a6d42f7.cjs.prod.js} +6 -6
- package/dist/{singleProducerAsyncInput-f9b258b1.cjs.prod.js → singleProducerAsyncInput-8b8ad112.cjs.prod.js} +1 -1
- package/dist/{singleProducerAsyncInput-9ff8389b.cjs.dev.js → singleProducerAsyncInput-97f74016.cjs.dev.js} +1 -1
- package/dist/{sink-572d8981.cjs.prod.js → sink-6d1a77bf.cjs.prod.js} +3 -3
- package/dist/{sink-8d3427e7.cjs.dev.js → sink-ebf2fbdb.cjs.dev.js} +3 -3
- package/dist/{stm-f250b596.cjs.prod.js → stm-4a6de085.cjs.prod.js} +3 -3
- package/dist/{stm-8aca0022.cjs.dev.js → stm-dbec85f1.cjs.dev.js} +3 -3
- package/dist/{stream-34d80d2c.cjs.dev.js → stream-478aa5a8.cjs.dev.js} +9 -6
- package/dist/{stream-ea4f4d44.cjs.prod.js → stream-f7345889.cjs.prod.js} +9 -6
- package/dist/{synchronizedRef-ed8aa6ac.cjs.prod.js → synchronizedRef-432b4455.cjs.prod.js} +1 -1
- package/dist/{synchronizedRef-a12fd967.cjs.dev.js → synchronizedRef-fa63e917.cjs.dev.js} +1 -1
- package/dist/{tArray-17f078f2.cjs.dev.js → tArray-0c9045e7.cjs.dev.js} +3 -3
- package/dist/{tArray-d184e22f.cjs.prod.js → tArray-b30ccc3e.cjs.prod.js} +3 -3
- package/dist/{tMap-e219f30e.cjs.prod.js → tMap-001c791c.cjs.prod.js} +4 -4
- package/dist/{tMap-1a5aa78b.cjs.dev.js → tMap-0625df1d.cjs.dev.js} +4 -4
- package/dist/{tQueue-47129ad0.cjs.prod.js → tQueue-6accdd70.cjs.prod.js} +3 -3
- package/dist/{tQueue-0a4fc773.cjs.dev.js → tQueue-cdbf9130.cjs.dev.js} +3 -3
- package/dist/{tRef-ab4c5713.cjs.prod.js → tRef-8b60d85b.cjs.prod.js} +1 -1
- package/dist/{tRef-b860ef05.cjs.dev.js → tRef-b5bae36d.cjs.dev.js} +1 -1
- package/internal/channel.esm.js +2 -2
- package/internal/core-effect.esm.js +1 -1
- package/internal/fiberRuntime.esm.js +27 -23
- package/internal/layer/circular.esm.js +5 -6
- package/internal/layer.esm.js +9 -5
- package/internal/logger.esm.js +3 -3
- package/internal/matcher.esm.js +314 -0
- package/internal/queue.esm.js +24 -14
- package/internal/stream.esm.js +7 -4
- package/internal/tracer.esm.js +14 -4
- package/package.json +21 -13
- package/src/{Bigint.ts → BigInt.ts} +26 -26
- package/src/Channel.ts +4 -2
- package/src/Data.ts +18 -16
- package/src/Duration.ts +2 -2
- package/src/Effect.ts +84 -151
- package/src/Either.ts +33 -0
- package/src/FiberRef.ts +2 -3
- package/src/Layer.ts +157 -3
- package/src/Logger.ts +2 -8
- package/src/Match.ts +800 -0
- package/src/Predicate.ts +4 -4
- package/src/Queue.ts +8 -0
- package/src/Stream.ts +4 -2
- package/src/Tracer.ts +18 -9
- package/src/index.ts +6 -1
- package/src/internal/channel.ts +5 -3
- package/src/internal/core-effect.ts +27 -22
- package/src/internal/core.ts +5 -7
- package/src/internal/fiberRuntime.ts +39 -13
- package/src/internal/layer/circular.ts +21 -6
- package/src/internal/layer.ts +20 -4
- package/src/internal/logger.ts +4 -4
- package/src/internal/matcher.ts +594 -0
- package/src/internal/queue.ts +26 -11
- package/src/internal/stream.ts +9 -7
- package/src/internal/tracer.ts +28 -5
- package/src/tsconfig.json +41 -0
- package/Bigint/dist/effect-Bigint.cjs.d.mts +0 -2
- package/Bigint/dist/effect-Bigint.cjs.d.mts.map +0 -1
- package/Bigint/dist/effect-Bigint.cjs.d.ts +0 -2
- package/Bigint/dist/effect-Bigint.cjs.d.ts.map +0 -1
- package/Bigint/dist/effect-Bigint.cjs.js +0 -7
- package/Bigint/package.json +0 -4
- /package/dist/{Effectable-c4c14a2b.cjs.prod.js → Effectable-6a8a05f1.cjs.prod.js} +0 -0
- /package/dist/{Effectable-7314aed8.cjs.dev.js → Effectable-71c10ab9.cjs.dev.js} +0 -0
- /package/dist/{FiberId-1d7ac632.cjs.prod.js → FiberId-54d8bd67.cjs.prod.js} +0 -0
- /package/dist/{FiberId-d88ddce6.cjs.dev.js → FiberId-6708cdca.cjs.dev.js} +0 -0
- /package/dist/{HashSet-ac02a3e1.cjs.prod.js → HashSet-86613304.cjs.prod.js} +0 -0
- /package/dist/{HashSet-5963ad6b.cjs.dev.js → HashSet-dd020cb0.cjs.dev.js} +0 -0
- /package/dist/{RuntimeFlagsPatch-866fa259.cjs.prod.js → RuntimeFlagsPatch-902b4680.cjs.prod.js} +0 -0
- /package/dist/{RuntimeFlagsPatch-69102b03.cjs.dev.js → RuntimeFlagsPatch-cf423492.cjs.dev.js} +0 -0
- /package/dist/{boundaries-f212e414.cjs.dev.js → boundaries-b5265184.cjs.dev.js} +0 -0
- /package/dist/{boundaries-9af538e3.cjs.prod.js → boundaries-bfd86b3e.cjs.prod.js} +0 -0
- /package/dist/{configError-b43723af.cjs.prod.js → configError-856c7153.cjs.prod.js} +0 -0
- /package/dist/{configError-d5efe9c0.cjs.dev.js → configError-a824b415.cjs.dev.js} +0 -0
- /package/dist/{configSecret-e2faa181.cjs.prod.js → configSecret-9b941a86.cjs.prod.js} +0 -0
- /package/dist/{configSecret-3e8ae336.cjs.dev.js → configSecret-e7bb51da.cjs.dev.js} +0 -0
- /package/dist/{keyType-0c5e6178.cjs.prod.js → keyType-4ec0b247.cjs.prod.js} +0 -0
- /package/dist/{keyType-7c164b82.cjs.dev.js → keyType-f30c9fa4.cjs.dev.js} +0 -0
- /package/dist/{label-655343b5.cjs.prod.js → label-a588e6cd.cjs.prod.js} +0 -0
- /package/dist/{label-011edbe7.cjs.dev.js → label-b0cebeae.cjs.dev.js} +0 -0
- /package/dist/{state-0bdf02b7.cjs.prod.js → state-40d5dc71.cjs.prod.js} +0 -0
- /package/dist/{state-931050c4.cjs.dev.js → state-620f7a22.cjs.dev.js} +0 -0
- /package/dist/{take-85daaf79.cjs.prod.js → take-15455ae3.cjs.prod.js} +0 -0
- /package/dist/{take-f9ef9e2e.cjs.dev.js → take-1c250e7a.cjs.dev.js} +0 -0
|
@@ -0,0 +1,620 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var Either_dist_effectEither = require('../../Either/dist/effect-Either.cjs.dev.js');
|
|
6
|
+
var Function_dist_effectFunction = require('../../Function/dist/effect-Function.cjs.dev.js');
|
|
7
|
+
var Option_dist_effectOption = require('../../Option/dist/effect-Option.cjs.dev.js');
|
|
8
|
+
var Pipeable_dist_effectPipeable = require('../../Pipeable/dist/effect-Pipeable.cjs.dev.js');
|
|
9
|
+
var Predicate_dist_effectPredicate = require('../../Predicate/dist/effect-Predicate.cjs.dev.js');
|
|
10
|
+
require('../../Equivalence/dist/effect-Equivalence.cjs.dev.js');
|
|
11
|
+
require('../../dist/Either-e7500e90.cjs.dev.js');
|
|
12
|
+
require('../../Equal/dist/effect-Equal.cjs.dev.js');
|
|
13
|
+
require('../../Hash/dist/effect-Hash.cjs.dev.js');
|
|
14
|
+
require('../../GlobalValue/dist/effect-GlobalValue.cjs.dev.js');
|
|
15
|
+
require('../../Utils/dist/effect-Utils.cjs.dev.js');
|
|
16
|
+
require('../../Inspectable/dist/effect-Inspectable.cjs.dev.js');
|
|
17
|
+
require('../../dist/Option-01caa9d4.cjs.dev.js');
|
|
18
|
+
require('../../dist/Effectable-71c10ab9.cjs.dev.js');
|
|
19
|
+
require('../../Number/dist/effect-Number.cjs.dev.js');
|
|
20
|
+
require('../../Order/dist/effect-Order.cjs.dev.js');
|
|
21
|
+
|
|
22
|
+
/** @internal */
|
|
23
|
+
const TypeId = /*#__PURE__*/Symbol.for("@effect/matcher/Matcher");
|
|
24
|
+
const TypeMatcherProto = {
|
|
25
|
+
[TypeId]: {
|
|
26
|
+
_input: Function_dist_effectFunction.identity,
|
|
27
|
+
_filters: Function_dist_effectFunction.identity,
|
|
28
|
+
_remaining: Function_dist_effectFunction.identity,
|
|
29
|
+
_result: Function_dist_effectFunction.identity
|
|
30
|
+
},
|
|
31
|
+
_tag: "TypeMatcher",
|
|
32
|
+
add(_case) {
|
|
33
|
+
return makeTypeMatcher([...this.cases, _case]);
|
|
34
|
+
},
|
|
35
|
+
pipe() {
|
|
36
|
+
return Pipeable_dist_effectPipeable.pipeArguments(this, arguments);
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
function makeTypeMatcher(cases) {
|
|
40
|
+
const matcher = Object.create(TypeMatcherProto);
|
|
41
|
+
matcher.cases = cases;
|
|
42
|
+
return matcher;
|
|
43
|
+
}
|
|
44
|
+
const ValueMatcherProto = {
|
|
45
|
+
[TypeId]: {
|
|
46
|
+
_input: Function_dist_effectFunction.identity,
|
|
47
|
+
_filters: Function_dist_effectFunction.identity,
|
|
48
|
+
_result: Function_dist_effectFunction.identity
|
|
49
|
+
},
|
|
50
|
+
_tag: "ValueMatcher",
|
|
51
|
+
add(_case) {
|
|
52
|
+
if (this.value._tag === "Right") {
|
|
53
|
+
return this;
|
|
54
|
+
}
|
|
55
|
+
if (_case._tag === "When" && _case.guard(this.provided) === true) {
|
|
56
|
+
return makeValueMatcher(this.provided, Either_dist_effectEither.right(_case.evaluate(this.provided)));
|
|
57
|
+
} else if (_case._tag === "Not" && _case.guard(this.provided) === false) {
|
|
58
|
+
return makeValueMatcher(this.provided, Either_dist_effectEither.right(_case.evaluate(this.provided)));
|
|
59
|
+
}
|
|
60
|
+
return this;
|
|
61
|
+
},
|
|
62
|
+
pipe() {
|
|
63
|
+
return Pipeable_dist_effectPipeable.pipeArguments(this, arguments);
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
function makeValueMatcher(provided, value) {
|
|
67
|
+
const matcher = Object.create(ValueMatcherProto);
|
|
68
|
+
matcher.provided = provided;
|
|
69
|
+
matcher.value = value;
|
|
70
|
+
return matcher;
|
|
71
|
+
}
|
|
72
|
+
const makeWhen = (guard, evaluate) => ({
|
|
73
|
+
_tag: "When",
|
|
74
|
+
guard,
|
|
75
|
+
evaluate
|
|
76
|
+
});
|
|
77
|
+
const makeNot = (guard, evaluate) => ({
|
|
78
|
+
_tag: "Not",
|
|
79
|
+
guard,
|
|
80
|
+
evaluate
|
|
81
|
+
});
|
|
82
|
+
const makePredicate = pattern => {
|
|
83
|
+
if (typeof pattern === "function") {
|
|
84
|
+
return pattern;
|
|
85
|
+
} else if (Array.isArray(pattern)) {
|
|
86
|
+
const predicates = pattern.map(makePredicate);
|
|
87
|
+
const len = predicates.length;
|
|
88
|
+
return u => {
|
|
89
|
+
if (!Array.isArray(u)) {
|
|
90
|
+
return false;
|
|
91
|
+
}
|
|
92
|
+
for (let i = 0; i < len; i++) {
|
|
93
|
+
if (predicates[i](u[i]) === false) {
|
|
94
|
+
return false;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
return true;
|
|
98
|
+
};
|
|
99
|
+
} else if (pattern !== null && typeof pattern === "object") {
|
|
100
|
+
const keysAndPredicates = Object.entries(pattern).map(([k, p]) => [k, makePredicate(p)]);
|
|
101
|
+
const len = keysAndPredicates.length;
|
|
102
|
+
return u => {
|
|
103
|
+
if (typeof u !== "object" || u === null) {
|
|
104
|
+
return false;
|
|
105
|
+
}
|
|
106
|
+
for (let i = 0; i < len; i++) {
|
|
107
|
+
const [key, predicate] = keysAndPredicates[i];
|
|
108
|
+
if (!(key in u) || predicate(u[key]) === false) {
|
|
109
|
+
return false;
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
return true;
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
return u => u === pattern;
|
|
116
|
+
};
|
|
117
|
+
const makeOrPredicate = patterns => {
|
|
118
|
+
const predicates = patterns.map(makePredicate);
|
|
119
|
+
const len = predicates.length;
|
|
120
|
+
return u => {
|
|
121
|
+
for (let i = 0; i < len; i++) {
|
|
122
|
+
if (predicates[i](u) === true) {
|
|
123
|
+
return true;
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
return false;
|
|
127
|
+
};
|
|
128
|
+
};
|
|
129
|
+
const makeAndPredicate = patterns => {
|
|
130
|
+
const predicates = patterns.map(makePredicate);
|
|
131
|
+
const len = predicates.length;
|
|
132
|
+
return u => {
|
|
133
|
+
for (let i = 0; i < len; i++) {
|
|
134
|
+
if (predicates[i](u) === false) {
|
|
135
|
+
return false;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
return true;
|
|
139
|
+
};
|
|
140
|
+
};
|
|
141
|
+
|
|
142
|
+
/** @internal */
|
|
143
|
+
const type$1 = () => makeTypeMatcher([]);
|
|
144
|
+
|
|
145
|
+
/** @internal */
|
|
146
|
+
const value$1 = i => makeValueMatcher(i, Either_dist_effectEither.left(i));
|
|
147
|
+
|
|
148
|
+
/** @internal */
|
|
149
|
+
const valueTags$1 = fields => {
|
|
150
|
+
const match = tagsExhaustive$1(fields)(makeTypeMatcher([]));
|
|
151
|
+
return input => match(input);
|
|
152
|
+
};
|
|
153
|
+
|
|
154
|
+
/** @internal */
|
|
155
|
+
const typeTags$1 = () => fields => {
|
|
156
|
+
const match = tagsExhaustive$1(fields)(makeTypeMatcher([]));
|
|
157
|
+
return input => match(input);
|
|
158
|
+
};
|
|
159
|
+
|
|
160
|
+
/** @internal */
|
|
161
|
+
const when$1 = (pattern, f) => self => self.add(makeWhen(makePredicate(pattern), f));
|
|
162
|
+
|
|
163
|
+
/** @internal */
|
|
164
|
+
const whenOr$1 = (...args) => self => {
|
|
165
|
+
const onMatch = args[args.length - 1];
|
|
166
|
+
const patterns = args.slice(0, -1);
|
|
167
|
+
return self.add(makeWhen(makeOrPredicate(patterns), onMatch));
|
|
168
|
+
};
|
|
169
|
+
|
|
170
|
+
/** @internal */
|
|
171
|
+
const whenAnd$1 = (...args) => self => {
|
|
172
|
+
const onMatch = args[args.length - 1];
|
|
173
|
+
const patterns = args.slice(0, -1);
|
|
174
|
+
return self.add(makeWhen(makeAndPredicate(patterns), onMatch));
|
|
175
|
+
};
|
|
176
|
+
|
|
177
|
+
/** @internal */
|
|
178
|
+
const discriminator$1 = field => (...pattern) => {
|
|
179
|
+
const f = pattern[pattern.length - 1];
|
|
180
|
+
const values = pattern.slice(0, -1);
|
|
181
|
+
const pred = values.length === 1 ? _ => _[field] === values[0] : _ => values.includes(_[field]);
|
|
182
|
+
return self => self.add(makeWhen(pred, f));
|
|
183
|
+
};
|
|
184
|
+
|
|
185
|
+
/** @internal */
|
|
186
|
+
const discriminatorStartsWith$1 = field => (pattern, f) => {
|
|
187
|
+
const pred = _ => typeof _[field] === "string" && _[field].startsWith(pattern);
|
|
188
|
+
return self => self.add(makeWhen(pred, f));
|
|
189
|
+
};
|
|
190
|
+
|
|
191
|
+
/** @internal */
|
|
192
|
+
const discriminators$1 = field => fields => {
|
|
193
|
+
const predicates = [];
|
|
194
|
+
for (const key in fields) {
|
|
195
|
+
const pred = _ => _[field] === key;
|
|
196
|
+
const f = fields[key];
|
|
197
|
+
if (f) {
|
|
198
|
+
predicates.push(makeWhen(pred, f));
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
const len = predicates.length;
|
|
202
|
+
return self => {
|
|
203
|
+
let matcher = self;
|
|
204
|
+
for (let i = 0; i < len; i++) {
|
|
205
|
+
matcher = matcher.add(predicates[i]);
|
|
206
|
+
}
|
|
207
|
+
return matcher;
|
|
208
|
+
};
|
|
209
|
+
};
|
|
210
|
+
|
|
211
|
+
/** @internal */
|
|
212
|
+
const discriminatorsExhaustive$1 = field => fields => {
|
|
213
|
+
const addCases = discriminators$1(field)(fields);
|
|
214
|
+
return matcher => exhaustive$1(addCases(matcher));
|
|
215
|
+
};
|
|
216
|
+
|
|
217
|
+
/** @internal */
|
|
218
|
+
const tag$1 = /*#__PURE__*/discriminator$1("_tag");
|
|
219
|
+
|
|
220
|
+
/** @internal */
|
|
221
|
+
const tagStartsWith$1 = /*#__PURE__*/discriminatorStartsWith$1("_tag");
|
|
222
|
+
|
|
223
|
+
/** @internal */
|
|
224
|
+
const tags$1 = /*#__PURE__*/discriminators$1("_tag");
|
|
225
|
+
|
|
226
|
+
/** @internal */
|
|
227
|
+
const tagsExhaustive$1 = /*#__PURE__*/discriminatorsExhaustive$1("_tag");
|
|
228
|
+
|
|
229
|
+
/** @internal */
|
|
230
|
+
const not$1 = (pattern, f) => self => self.add(makeNot(makePredicate(pattern), f));
|
|
231
|
+
|
|
232
|
+
/** @internal */
|
|
233
|
+
const nonEmptyString$1 = u => typeof u === "string" && u.length > 0;
|
|
234
|
+
|
|
235
|
+
/** @internal */
|
|
236
|
+
const is$1 = (...literals) => {
|
|
237
|
+
const len = literals.length;
|
|
238
|
+
return u => {
|
|
239
|
+
for (let i = 0; i < len; i++) {
|
|
240
|
+
if (u === literals[i]) {
|
|
241
|
+
return true;
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
return false;
|
|
245
|
+
};
|
|
246
|
+
};
|
|
247
|
+
|
|
248
|
+
/** @internal */
|
|
249
|
+
const any$1 = () => true;
|
|
250
|
+
|
|
251
|
+
/** @internal */
|
|
252
|
+
const defined$1 = u => u !== undefined && u !== null;
|
|
253
|
+
|
|
254
|
+
/** @internal */
|
|
255
|
+
const instanceOf$1 = constructor => u => u instanceof constructor;
|
|
256
|
+
|
|
257
|
+
/** @internal */
|
|
258
|
+
const orElse$1 = f => self => {
|
|
259
|
+
const result = either$1(self);
|
|
260
|
+
if (Either_dist_effectEither.isEither(result)) {
|
|
261
|
+
// @ts-expect-error
|
|
262
|
+
return result._tag === "Right" ? result.right : f(result.left);
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
// @ts-expect-error
|
|
266
|
+
return input => {
|
|
267
|
+
const a = result(input);
|
|
268
|
+
return a._tag === "Right" ? a.right : f(a.left);
|
|
269
|
+
};
|
|
270
|
+
};
|
|
271
|
+
|
|
272
|
+
/** @internal */
|
|
273
|
+
const orElseAbsurd$1 = self => orElse$1(() => {
|
|
274
|
+
throw new Error("absurd");
|
|
275
|
+
})(self);
|
|
276
|
+
|
|
277
|
+
/** @internal */
|
|
278
|
+
const either$1 = self => {
|
|
279
|
+
if (self._tag === "ValueMatcher") {
|
|
280
|
+
return self.value;
|
|
281
|
+
}
|
|
282
|
+
const len = self.cases.length;
|
|
283
|
+
return input => {
|
|
284
|
+
for (let i = 0; i < len; i++) {
|
|
285
|
+
const _case = self.cases[i];
|
|
286
|
+
if (_case._tag === "When" && _case.guard(input) === true) {
|
|
287
|
+
return Either_dist_effectEither.right(_case.evaluate(input));
|
|
288
|
+
} else if (_case._tag === "Not" && _case.guard(input) === false) {
|
|
289
|
+
return Either_dist_effectEither.right(_case.evaluate(input));
|
|
290
|
+
}
|
|
291
|
+
}
|
|
292
|
+
return Either_dist_effectEither.left(input);
|
|
293
|
+
};
|
|
294
|
+
};
|
|
295
|
+
|
|
296
|
+
/** @internal */
|
|
297
|
+
const option$1 = self => {
|
|
298
|
+
const toEither = either$1(self);
|
|
299
|
+
if (Either_dist_effectEither.isEither(toEither)) {
|
|
300
|
+
return Either_dist_effectEither.match(toEither, {
|
|
301
|
+
onLeft: () => Option_dist_effectOption.none(),
|
|
302
|
+
onRight: Option_dist_effectOption.some
|
|
303
|
+
});
|
|
304
|
+
}
|
|
305
|
+
return input => Either_dist_effectEither.match(toEither(input), {
|
|
306
|
+
onLeft: () => Option_dist_effectOption.none(),
|
|
307
|
+
onRight: Option_dist_effectOption.some
|
|
308
|
+
});
|
|
309
|
+
};
|
|
310
|
+
|
|
311
|
+
/** @internal */
|
|
312
|
+
const exhaustive$1 = self => {
|
|
313
|
+
const toEither = either$1(self);
|
|
314
|
+
if (Either_dist_effectEither.isEither(toEither)) {
|
|
315
|
+
if (toEither._tag === "Right") {
|
|
316
|
+
return toEither.right;
|
|
317
|
+
}
|
|
318
|
+
throw new Error("@effect/match: exhaustive absurd");
|
|
319
|
+
}
|
|
320
|
+
return u => {
|
|
321
|
+
// @ts-expect-error
|
|
322
|
+
const result = toEither(u);
|
|
323
|
+
if (result._tag === "Right") {
|
|
324
|
+
return result.right;
|
|
325
|
+
}
|
|
326
|
+
throw new Error("@effect/match: exhaustive absurd");
|
|
327
|
+
};
|
|
328
|
+
};
|
|
329
|
+
|
|
330
|
+
/**
|
|
331
|
+
* @since 1.0.0
|
|
332
|
+
*/
|
|
333
|
+
/**
|
|
334
|
+
* @category type ids
|
|
335
|
+
* @since 1.0.0
|
|
336
|
+
*/
|
|
337
|
+
const MatcherTypeId = TypeId;
|
|
338
|
+
|
|
339
|
+
/**
|
|
340
|
+
* @category type ids
|
|
341
|
+
* @since 1.0.0
|
|
342
|
+
*/
|
|
343
|
+
|
|
344
|
+
/**
|
|
345
|
+
* @category model
|
|
346
|
+
* @since 1.0.0
|
|
347
|
+
*/
|
|
348
|
+
|
|
349
|
+
/**
|
|
350
|
+
* @category model
|
|
351
|
+
* @since 1.0.0
|
|
352
|
+
*/
|
|
353
|
+
|
|
354
|
+
/**
|
|
355
|
+
* @category model
|
|
356
|
+
* @since 1.0.0
|
|
357
|
+
*/
|
|
358
|
+
|
|
359
|
+
/**
|
|
360
|
+
* @category model
|
|
361
|
+
* @since 1.0.0
|
|
362
|
+
*/
|
|
363
|
+
|
|
364
|
+
/**
|
|
365
|
+
* @category model
|
|
366
|
+
* @since 1.0.0
|
|
367
|
+
*/
|
|
368
|
+
|
|
369
|
+
/**
|
|
370
|
+
* @category model
|
|
371
|
+
* @since 1.0.0
|
|
372
|
+
*/
|
|
373
|
+
|
|
374
|
+
/**
|
|
375
|
+
* @category constructors
|
|
376
|
+
* @since 1.0.0
|
|
377
|
+
*/
|
|
378
|
+
const type = type$1;
|
|
379
|
+
|
|
380
|
+
/**
|
|
381
|
+
* @category constructors
|
|
382
|
+
* @since 1.0.0
|
|
383
|
+
*/
|
|
384
|
+
const value = value$1;
|
|
385
|
+
|
|
386
|
+
/**
|
|
387
|
+
* @category constructors
|
|
388
|
+
* @since 1.0.0
|
|
389
|
+
*/
|
|
390
|
+
const valueTags = valueTags$1;
|
|
391
|
+
|
|
392
|
+
/**
|
|
393
|
+
* @category constructors
|
|
394
|
+
* @since 1.0.0
|
|
395
|
+
*/
|
|
396
|
+
const typeTags = typeTags$1;
|
|
397
|
+
|
|
398
|
+
/**
|
|
399
|
+
* @category combinators
|
|
400
|
+
* @since 1.0.0
|
|
401
|
+
*/
|
|
402
|
+
const when = when$1;
|
|
403
|
+
|
|
404
|
+
/**
|
|
405
|
+
* @category combinators
|
|
406
|
+
* @since 1.0.0
|
|
407
|
+
*/
|
|
408
|
+
const whenOr = whenOr$1;
|
|
409
|
+
|
|
410
|
+
/**
|
|
411
|
+
* @category combinators
|
|
412
|
+
* @since 1.0.0
|
|
413
|
+
*/
|
|
414
|
+
const whenAnd = whenAnd$1;
|
|
415
|
+
|
|
416
|
+
/**
|
|
417
|
+
* @category combinators
|
|
418
|
+
* @since 1.0.0
|
|
419
|
+
*/
|
|
420
|
+
const discriminator = discriminator$1;
|
|
421
|
+
|
|
422
|
+
/**
|
|
423
|
+
* @category combinators
|
|
424
|
+
* @since 1.0.0
|
|
425
|
+
*/
|
|
426
|
+
const discriminatorStartsWith = discriminatorStartsWith$1;
|
|
427
|
+
|
|
428
|
+
/**
|
|
429
|
+
* @category combinators
|
|
430
|
+
* @since 1.0.0
|
|
431
|
+
*/
|
|
432
|
+
const discriminators = discriminators$1;
|
|
433
|
+
|
|
434
|
+
/**
|
|
435
|
+
* @category combinators
|
|
436
|
+
* @since 1.0.0
|
|
437
|
+
*/
|
|
438
|
+
const discriminatorsExhaustive = discriminatorsExhaustive$1;
|
|
439
|
+
|
|
440
|
+
/**
|
|
441
|
+
* @category combinators
|
|
442
|
+
* @since 1.0.0
|
|
443
|
+
*/
|
|
444
|
+
const tag = tag$1;
|
|
445
|
+
|
|
446
|
+
/**
|
|
447
|
+
* @category combinators
|
|
448
|
+
* @since 1.0.0
|
|
449
|
+
*/
|
|
450
|
+
const tagStartsWith = tagStartsWith$1;
|
|
451
|
+
|
|
452
|
+
/**
|
|
453
|
+
* @category combinators
|
|
454
|
+
* @since 1.0.0
|
|
455
|
+
*/
|
|
456
|
+
const tags = tags$1;
|
|
457
|
+
|
|
458
|
+
/**
|
|
459
|
+
* @category combinators
|
|
460
|
+
* @since 1.0.0
|
|
461
|
+
*/
|
|
462
|
+
const tagsExhaustive = tagsExhaustive$1;
|
|
463
|
+
|
|
464
|
+
/**
|
|
465
|
+
* @category combinators
|
|
466
|
+
* @since 1.0.0
|
|
467
|
+
*/
|
|
468
|
+
const not = not$1;
|
|
469
|
+
|
|
470
|
+
/**
|
|
471
|
+
* @category predicates
|
|
472
|
+
* @since 1.0.0
|
|
473
|
+
*/
|
|
474
|
+
const nonEmptyString = nonEmptyString$1;
|
|
475
|
+
|
|
476
|
+
/**
|
|
477
|
+
* @category predicates
|
|
478
|
+
* @since 1.0.0
|
|
479
|
+
*/
|
|
480
|
+
const is = is$1;
|
|
481
|
+
|
|
482
|
+
/**
|
|
483
|
+
* @category predicates
|
|
484
|
+
* @since 1.0.0
|
|
485
|
+
*/
|
|
486
|
+
const string = Predicate_dist_effectPredicate.isString;
|
|
487
|
+
|
|
488
|
+
/**
|
|
489
|
+
* @category predicates
|
|
490
|
+
* @since 1.0.0
|
|
491
|
+
*/
|
|
492
|
+
const number = Predicate_dist_effectPredicate.isNumber;
|
|
493
|
+
|
|
494
|
+
/**
|
|
495
|
+
* @category predicates
|
|
496
|
+
* @since 1.0.0
|
|
497
|
+
*/
|
|
498
|
+
const any = any$1;
|
|
499
|
+
|
|
500
|
+
/**
|
|
501
|
+
* @category predicates
|
|
502
|
+
* @since 1.0.0
|
|
503
|
+
*/
|
|
504
|
+
const defined = defined$1;
|
|
505
|
+
|
|
506
|
+
/**
|
|
507
|
+
* @category predicates
|
|
508
|
+
* @since 1.0.0
|
|
509
|
+
*/
|
|
510
|
+
const boolean = Predicate_dist_effectPredicate.isBoolean;
|
|
511
|
+
const _undefined = Predicate_dist_effectPredicate.isUndefined;
|
|
512
|
+
const _null = Predicate_dist_effectPredicate.isNull;
|
|
513
|
+
|
|
514
|
+
/**
|
|
515
|
+
* @category predicates
|
|
516
|
+
* @since 1.0.0
|
|
517
|
+
*/
|
|
518
|
+
const bigint = Predicate_dist_effectPredicate.isBigInt;
|
|
519
|
+
|
|
520
|
+
/**
|
|
521
|
+
* @category predicates
|
|
522
|
+
* @since 1.0.0
|
|
523
|
+
*/
|
|
524
|
+
const date = Predicate_dist_effectPredicate.isDate;
|
|
525
|
+
|
|
526
|
+
/**
|
|
527
|
+
* @category predicates
|
|
528
|
+
* @since 1.0.0
|
|
529
|
+
*/
|
|
530
|
+
const record = Predicate_dist_effectPredicate.isRecord;
|
|
531
|
+
|
|
532
|
+
/**
|
|
533
|
+
* @category predicates
|
|
534
|
+
* @since 1.0.0
|
|
535
|
+
*/
|
|
536
|
+
const instanceOf = instanceOf$1;
|
|
537
|
+
|
|
538
|
+
/**
|
|
539
|
+
* @category predicates
|
|
540
|
+
* @since 1.0.0
|
|
541
|
+
*/
|
|
542
|
+
const instanceOfUnsafe = instanceOf$1;
|
|
543
|
+
|
|
544
|
+
/**
|
|
545
|
+
* @category conversions
|
|
546
|
+
* @since 1.0.0
|
|
547
|
+
*/
|
|
548
|
+
const orElse = orElse$1;
|
|
549
|
+
|
|
550
|
+
/**
|
|
551
|
+
* @category conversions
|
|
552
|
+
* @since 1.0.0
|
|
553
|
+
*/
|
|
554
|
+
const orElseAbsurd = orElseAbsurd$1;
|
|
555
|
+
|
|
556
|
+
/**
|
|
557
|
+
* @category conversions
|
|
558
|
+
* @since 1.0.0
|
|
559
|
+
*/
|
|
560
|
+
const either = either$1;
|
|
561
|
+
|
|
562
|
+
/**
|
|
563
|
+
* @category conversions
|
|
564
|
+
* @since 1.0.0
|
|
565
|
+
*/
|
|
566
|
+
const option = option$1;
|
|
567
|
+
|
|
568
|
+
/**
|
|
569
|
+
* @category conversions
|
|
570
|
+
* @since 1.0.0
|
|
571
|
+
*/
|
|
572
|
+
const exhaustive = exhaustive$1;
|
|
573
|
+
|
|
574
|
+
/**
|
|
575
|
+
* @since 1.0.0
|
|
576
|
+
* @category type ids
|
|
577
|
+
*/
|
|
578
|
+
const SafeRefinementId = /*#__PURE__*/Symbol.for("./SafeRefinement");
|
|
579
|
+
|
|
580
|
+
/**
|
|
581
|
+
* @since 1.0.0
|
|
582
|
+
*/
|
|
583
|
+
|
|
584
|
+
exports.MatcherTypeId = MatcherTypeId;
|
|
585
|
+
exports.SafeRefinementId = SafeRefinementId;
|
|
586
|
+
exports.any = any;
|
|
587
|
+
exports.bigint = bigint;
|
|
588
|
+
exports.boolean = boolean;
|
|
589
|
+
exports.date = date;
|
|
590
|
+
exports.defined = defined;
|
|
591
|
+
exports.discriminator = discriminator;
|
|
592
|
+
exports.discriminatorStartsWith = discriminatorStartsWith;
|
|
593
|
+
exports.discriminators = discriminators;
|
|
594
|
+
exports.discriminatorsExhaustive = discriminatorsExhaustive;
|
|
595
|
+
exports.either = either;
|
|
596
|
+
exports.exhaustive = exhaustive;
|
|
597
|
+
exports.instanceOf = instanceOf;
|
|
598
|
+
exports.instanceOfUnsafe = instanceOfUnsafe;
|
|
599
|
+
exports.is = is;
|
|
600
|
+
exports.nonEmptyString = nonEmptyString;
|
|
601
|
+
exports.not = not;
|
|
602
|
+
exports["null"] = _null;
|
|
603
|
+
exports.number = number;
|
|
604
|
+
exports.option = option;
|
|
605
|
+
exports.orElse = orElse;
|
|
606
|
+
exports.orElseAbsurd = orElseAbsurd;
|
|
607
|
+
exports.record = record;
|
|
608
|
+
exports.string = string;
|
|
609
|
+
exports.tag = tag;
|
|
610
|
+
exports.tagStartsWith = tagStartsWith;
|
|
611
|
+
exports.tags = tags;
|
|
612
|
+
exports.tagsExhaustive = tagsExhaustive;
|
|
613
|
+
exports.type = type;
|
|
614
|
+
exports.typeTags = typeTags;
|
|
615
|
+
exports["undefined"] = _undefined;
|
|
616
|
+
exports.value = value;
|
|
617
|
+
exports.valueTags = valueTags;
|
|
618
|
+
exports.when = when;
|
|
619
|
+
exports.whenAnd = whenAnd;
|
|
620
|
+
exports.whenOr = whenOr;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
export {
|
|
2
|
+
MatcherTypeId,
|
|
3
|
+
SafeRefinementId,
|
|
4
|
+
any,
|
|
5
|
+
bigint,
|
|
6
|
+
boolean,
|
|
7
|
+
date,
|
|
8
|
+
defined,
|
|
9
|
+
discriminator,
|
|
10
|
+
discriminatorStartsWith,
|
|
11
|
+
discriminators,
|
|
12
|
+
discriminatorsExhaustive,
|
|
13
|
+
either,
|
|
14
|
+
exhaustive,
|
|
15
|
+
instanceOf,
|
|
16
|
+
instanceOfUnsafe,
|
|
17
|
+
is,
|
|
18
|
+
nonEmptyString,
|
|
19
|
+
not,
|
|
20
|
+
null,
|
|
21
|
+
number,
|
|
22
|
+
option,
|
|
23
|
+
orElse,
|
|
24
|
+
orElseAbsurd,
|
|
25
|
+
record,
|
|
26
|
+
string,
|
|
27
|
+
tag,
|
|
28
|
+
tagStartsWith,
|
|
29
|
+
tags,
|
|
30
|
+
tagsExhaustive,
|
|
31
|
+
type,
|
|
32
|
+
typeTags,
|
|
33
|
+
undefined,
|
|
34
|
+
value,
|
|
35
|
+
valueTags,
|
|
36
|
+
when,
|
|
37
|
+
whenAnd,
|
|
38
|
+
whenOr
|
|
39
|
+
} from "./effect-Match.cjs.js";
|