Sha256: 044889b7f4a6df98293d1036c76e84f9437bf918dc9abe4b8a52751542bef1e2
Contents?: true
Size: 404 Bytes
Versions: 2
Compression:
Stored size: 404 Bytes
Contents
# frozen_string_literal: true require 'dry/effects/provider' module Dry module Effects module Providers class Fork < Provider[:fork] attr_reader :stack def fork stack = self.stack.dup -> &cont { Handler.spawn_fiber(stack.dup, &cont) } end def call(stack) @stack = stack super end end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
dry-effects-0.1.0.alpha2 | lib/dry/effects/providers/fork.rb |
dry-effects-0.1.0.alpha | lib/dry/effects/providers/fork.rb |