backports 3.14.0 → 3.15.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e3083b4e87452fa1cbc1ed0d598c41bff5e88841f34c616ccf881691633a45b3
4
- data.tar.gz: 70c248532e302112a98bb58809f366997e36031c211dff5d40a5d933b39270e2
3
+ metadata.gz: dfaaf8b4d959d53366fc8ae0651a20195e5f3489db9056f08b25072f7e07c951
4
+ data.tar.gz: 6febf4408b08ea3be934e88ce8d91534e7cd06acf76684e01dcceb3b27fbd772
5
5
  SHA512:
6
- metadata.gz: 19c74b246816260733f97bacef04d546ae6201f6ae80740d827784540572439e09c412c6253db58663dc93511e11d4b8ef871b54b4f1fe08487da06090c72498
7
- data.tar.gz: abc48b0560e6d9503e4e42122dc437cfc24a1fbd1e3a4b8e9a1df7d71863146a29363adc05743f80689e2a5d280bf0674f8c8da2d0a3cad999d04b6295e662d5
6
+ metadata.gz: eabe82c6a6c2e7e29b94f7f8c013faeb45a0c5224232fe47bdaab02d9d41ac09543aed1ecf2870a728f6cb517f2c35b6a99682a29a12550a38d9207dabb84403
7
+ data.tar.gz: dea3961cfcf98e9f5867dc9483ee94d85a94051f393da6a280f3710578cb1bd2a9e91f4bbd65bea08e68c5e8735a7cb2b447201fec57a32e347d37481d4d6164
@@ -1,5 +1,10 @@
1
1
  = Backports --- History
2
2
 
3
+ == Version 3.15.0 - May 15th, 2019
4
+
5
+ * Proc / Method
6
+ * +<<+, +>>+
7
+
3
8
  == Version 3.14.0 - April 29th, 2019
4
9
 
5
10
  * Hash
@@ -94,6 +94,12 @@ Compatible with Ruby itself, JRuby and Rubinius.
94
94
  * Kernel
95
95
  * +then+
96
96
 
97
+ * Method
98
+ * +<<+, +>>+
99
+
100
+ * Proc
101
+ * +<<+, +>>+
102
+
97
103
  == Ruby 2.5 backports
98
104
 
99
105
  * Array
@@ -0,0 +1,3 @@
1
+ require 'backports/tools/require_relative_dir'
2
+
3
+ Backports.require_relative_dir
@@ -0,0 +1,13 @@
1
+ unless Method.method_defined?(:<<) || Method.method_defined?(:>>)
2
+ require 'backports/2.6.0/proc/compose'
3
+
4
+ class Method
5
+ def <<(g)
6
+ to_proc << g
7
+ end
8
+
9
+ def >>(g)
10
+ to_proc >> g
11
+ end
12
+ end
13
+ end
@@ -0,0 +1,3 @@
1
+ require 'backports/tools/require_relative_dir'
2
+
3
+ Backports.require_relative_dir
@@ -0,0 +1,19 @@
1
+ unless Proc.method_defined?(:<<) || Proc.method_defined?(:>>)
2
+ class Proc
3
+ def <<(g)
4
+ if lambda?
5
+ lambda { |*args, &blk| call(g.call(*args, &blk)) }
6
+ else
7
+ proc { |*args, &blk| call(g.call(*args, &blk)) }
8
+ end
9
+ end
10
+
11
+ def >>(g)
12
+ if lambda?
13
+ lambda { |*args, &blk| g.call(call(*args, &blk)) }
14
+ else
15
+ proc { |*args, &blk| g.call(call(*args, &blk)) }
16
+ end
17
+ end
18
+ end
19
+ end
@@ -1,3 +1,3 @@
1
1
  module Backports
2
- VERSION = "3.14.0" unless const_defined? :VERSION # the guard is against a redefinition warning that happens on Travis
2
+ VERSION = "3.15.0" unless const_defined? :VERSION # the guard is against a redefinition warning that happens on Travis
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: backports
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.14.0
4
+ version: 3.15.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Marc-André Lafortune
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-04-29 00:00:00.000000000 Z
11
+ date: 2019-05-15 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Essential backports that enable many of the nice features of Ruby for
14
14
  earlier versions.
@@ -760,6 +760,10 @@ files:
760
760
  - lib/backports/2.6.0/hash/update.rb
761
761
  - lib/backports/2.6.0/kernel.rb
762
762
  - lib/backports/2.6.0/kernel/then.rb
763
+ - lib/backports/2.6.0/method.rb
764
+ - lib/backports/2.6.0/method/compose.rb
765
+ - lib/backports/2.6.0/proc.rb
766
+ - lib/backports/2.6.0/proc/compose.rb
763
767
  - lib/backports/2.6.rb
764
768
  - lib/backports/basic_object.rb
765
769
  - lib/backports/force/array_map.rb