dry-monads 1.7.0 → 1.7.1

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4c3b21d3e3072a7a21013aa3fc863b50e1aca7707122980adcc5313bff792743
4
- data.tar.gz: 9b3df76a0c3ce66eb88e8e1bf6b66804f43268b56cb407310944ca7e51614469
3
+ metadata.gz: 71e72f068689b13c930f32796d5d235638fbc8f685b4274070b6e418d1bb1ec3
4
+ data.tar.gz: 81523f64fc36c7ddfe4f9b90490f7477ad94d43abb52d9b594b9b0bb8b1f4c1f
5
5
  SHA512:
6
- metadata.gz: 4056e685a4f47e8168fc97ddb4d773ad5f257d9fcc9d484e35221016961ccb525c475b0f20a9ac48ea7f7a14bfbd6ebe98b4672d7695c687efb3ffd8ebd6244b
7
- data.tar.gz: 28740b0f45b4e782b9def280eb1f527ce2d970a901d60d883129c31338e481ebb9190836ceb63330e555958a873185d9ae6ad869edd22ab3623975564328d30f
6
+ metadata.gz: f9164e029f4482abaaa3bae2111607417ba3c3867ffc44f10a6626697ffa8793d291cc96518563d2eec8950f0594814167cf04f242f6354f581873256862b672
7
+ data.tar.gz: 8c915830df01f6461efe56db8c38ec248cb9778270a6b5f5f1b0c2464e0cb6794806d031a62c9e47ed770f0f964b38ba461599afa40d2ac2f35ecc71904961cd
data/CHANGELOG.md CHANGED
@@ -1,5 +1,15 @@
1
1
  <!--- DO NOT EDIT THIS FILE - IT'S AUTOMATICALLY GENERATED VIA DEVTOOLS --->
2
2
 
3
+ ## 1.7.1 2025-01-21
4
+
5
+
6
+ ### Fixed
7
+
8
+ - Fix warnings about unused block arguments (@flash-gordon)
9
+
10
+
11
+ [Compare v1.7.0...v1.7.1](https://github.com/dry-rb/dry-monads/compare/v1.7.0...v1.7.1)
12
+
3
13
  ## 1.7.0 2025-01-07
4
14
 
5
15
 
@@ -261,7 +261,7 @@ module Dry
261
261
  # @see Maybe::Some#filter
262
262
  #
263
263
  # @return [Maybe::None]
264
- def filter(_ = Undefined) = self
264
+ def filter(_ = Undefined, &) = self
265
265
  end
266
266
 
267
267
  # A module that can be included for easier access to Maybe monads.
@@ -126,7 +126,7 @@ module Dry
126
126
  # Ignores values and returns self, see {Failure#alt_map}
127
127
  #
128
128
  # @return [Result::Success]
129
- def alt_map(_ = nil) = self
129
+ def alt_map(_ = nil, &) = self
130
130
  end
131
131
 
132
132
  # Represents a value of a failed operation.
@@ -371,7 +371,7 @@ module Dry
371
371
  # @param fail [#call] Fallback value
372
372
  # @param block [Proc] Fallback block
373
373
  # @return [Success<Any>]
374
- def to_result(_fail = Unit) = Result::Success.new(@value)
374
+ def to_result(_fail = Unit, &) = Result::Success.new(@value)
375
375
  end
376
376
 
377
377
  class None < Maybe
@@ -94,7 +94,7 @@ module Dry
94
94
  # Returns value. It exists to keep the interface identical to that of RightBiased::Left
95
95
  #
96
96
  # @return [Object]
97
- def value_or(_val = nil) = @value
97
+ def value_or(_val = nil, &) = @value
98
98
 
99
99
  # Applies the stored value to the given argument if the argument has type of Right,
100
100
  # otherwise returns the argument.
@@ -316,7 +316,7 @@ module Dry
316
316
  # identical to that of {RightBiased::Right}.
317
317
  #
318
318
  # @return [RightBiased::Left]
319
- def and(_) = self
319
+ def and(_, &) = self
320
320
 
321
321
  # Pattern matching
322
322
  #
@@ -162,7 +162,7 @@ module Dry
162
162
  # @param errors [Class] List of Exception subclasses
163
163
  #
164
164
  # @return [Try::Value]
165
- def recover(*_errors) = self
165
+ def recover(*_errors, &) = self
166
166
  end
167
167
 
168
168
  # Represents a result of a failed execution.
@@ -103,12 +103,12 @@ module Dry
103
103
  # Ignores values and returns self, see {Invalid#alt_map}
104
104
  #
105
105
  # @return [Validated::Valid]
106
- def alt_map(_ = nil) = self
106
+ def alt_map(_ = nil, &) = self
107
107
 
108
108
  # Ignores arguments, returns self
109
109
  #
110
110
  # @return [Validated::Valid]
111
- def or(_ = nil) = self
111
+ def or(_ = nil, &) = self
112
112
 
113
113
  # @return [String]
114
114
  def inspect
@@ -185,7 +185,7 @@ module Dry
185
185
  # Ignores the passed argument and returns self
186
186
  #
187
187
  # @return [Validated::Invalid]
188
- def fmap(_ = nil) = self
188
+ def fmap(_ = nil, &) = self
189
189
 
190
190
  # Yields the given callable and returns the result
191
191
  #
@@ -3,6 +3,6 @@
3
3
  module Dry
4
4
  module Monads
5
5
  # Gem version
6
- VERSION = "1.7.0"
6
+ VERSION = "1.7.1"
7
7
  end
8
8
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dry-monads
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.7.0
4
+ version: 1.7.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nikita Shilnikov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-01-07 00:00:00.000000000 Z
11
+ date: 2025-01-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: concurrent-ruby