marameters 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/lib/marameters/categorizer.rb +2 -2
- data/lib/marameters/probe.rb +8 -3
- data/marameters.gemspec +1 -1
- data.tar.gz.sig +0 -0
- metadata +2 -2
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: '0239bc01a276d9772d90353fad489b7028ad67af2453952b79c8900216be0d87'
|
4
|
+
data.tar.gz: 849864aa69885987aa60c17ec2f7b05e7dd37520b47b6f84afc1b3df8cc75942
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d26d64a6e4d0e228cb909f1f76bcfedfa0eebb71f1621581fed7bf7c3d19c8eb3fce57d8574d148ae1be8130347c19f4f63352d72eaafca3c504cffea959b209
|
7
|
+
data.tar.gz: 1e713d605fbc0a6acce595f9425f082d1729741a4a601aa1ba857e548a74d4ba81a0df9de210d1a131dd3b3c51063c48ac4b084420802a2fc936500fe1f55bb5
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
@@ -34,8 +34,8 @@ module Marameters
|
|
34
34
|
|
35
35
|
def filter pair, value
|
36
36
|
case pair
|
37
|
-
in [:rest, :*] then splat_positional value
|
38
|
-
in [:keyrest, :**] then record.keywords = Hash value
|
37
|
+
in [:rest] | [:rest, :*] then splat_positional value
|
38
|
+
in [:keyrest] | [:keyrest, :**] then record.keywords = Hash value
|
39
39
|
in [:req, *] | [:opt, *] then record.positionals.append value
|
40
40
|
in [:rest, *] then record.positionals.append(*value)
|
41
41
|
in [:nokey] then nil
|
data/lib/marameters/probe.rb
CHANGED
@@ -46,12 +46,17 @@ module Marameters
|
|
46
46
|
def names = parameters.map { |_kind, name| name }
|
47
47
|
|
48
48
|
def only_bare_splats?
|
49
|
-
parameters in [[:rest
|
49
|
+
parameters in [[:rest]] \
|
50
|
+
| [[:keyrest]] \
|
51
|
+
| [[:rest], [:keyrest]] \
|
52
|
+
| [[:rest, :*]] \
|
53
|
+
| [[:keyrest, :**]] \
|
54
|
+
| [[:rest, :*], [:keyrest, :**]]
|
50
55
|
end
|
51
56
|
|
52
|
-
def only_double_splats? = (parameters in [[:keyrest, *]])
|
57
|
+
def only_double_splats? = (parameters in [[:keyrest]] | [[:keyrest, *]])
|
53
58
|
|
54
|
-
def only_single_splats? = (parameters in [[:rest, *]])
|
59
|
+
def only_single_splats? = (parameters in [[:rest]] | [[:rest, *]])
|
55
60
|
|
56
61
|
def positionals? = positionals.any?
|
57
62
|
|
data/marameters.gemspec
CHANGED
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: marameters
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brooke Kuhlmann
|
@@ -28,7 +28,7 @@ cert_chain:
|
|
28
28
|
CxDe2+VuChj4I1nvIHdu+E6XoEVlanUPKmSg6nddhkKn2gC45Kyzh6FZqnzH/CRp
|
29
29
|
RFE=
|
30
30
|
-----END CERTIFICATE-----
|
31
|
-
date: 2022-12-
|
31
|
+
date: 2022-12-27 00:00:00.000000000 Z
|
32
32
|
dependencies:
|
33
33
|
- !ruby/object:Gem::Dependency
|
34
34
|
name: refinements
|
metadata.gz.sig
CHANGED
Binary file
|