rmtools 1.2.12 → 1.2.13

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.
data/License.txt CHANGED
@@ -1,4 +1,5 @@
1
- Copyright (c) 2010 Anonymous <tinbka@gmail.com>
1
+ Copyright (c) 2010-2013
2
+ Sergey Baev <tinbka@gmail.com>
2
3
 
3
4
  This work is licensed under the same license as Ruby language.
4
5
 
data/README.txt CHANGED
@@ -1,5 +1,5 @@
1
1
  Copyright (c) 2010-2013
2
- Baev Sergey <tinbka@gmail.com>
2
+ Sergey Baev <tinbka@gmail.com>
3
3
 
4
4
  This work is licensed under the same license as Ruby language.
5
5
 
@@ -9,7 +9,7 @@ Methods for basic classes addon collection.
9
9
 
10
10
  == CHANGES
11
11
 
12
- == Version 1.2.12
12
+ == Version 1.2.13
13
13
 
14
14
  * Smartified Array bicycles: #index_where, #indices_where, #set_where, #set_all_where, #del_where, #del_all_where
15
15
  * Added #arrange_by to Array enumerators
data/Rakefile CHANGED
@@ -2,7 +2,7 @@ require 'rake'
2
2
  require './lib/rmtools/install'
3
3
  compile_manifest
4
4
 
5
- RMTOOLS_VERSION = '1.2.12'
5
+ RMTOOLS_VERSION = '1.2.13'
6
6
  begin
7
7
  require 'hoe'
8
8
  config = Hoe.spec 'rmtools' do
data/ext/rmtools.cpp CHANGED
@@ -423,7 +423,7 @@ static int unsigned_big_lte(VALUE x, VALUE y)
423
423
  long ylen = RBIGNUM_LEN(y);
424
424
  if (xlen < ylen) return 1;
425
425
  if (xlen > RBIGNUM_LEN(y)) return 0;
426
- while(xlen-- && (BDIGITS(x)[xlen]==BDIGITS(y)[xlen]));
426
+ while (xlen-- && (BDIGITS(x)[xlen]==BDIGITS(y)[xlen])) {};
427
427
  if (-1 == xlen) return 1; // ==
428
428
  return (BDIGITS(x)[xlen] > BDIGITS(y)[xlen]) ? 0 : 1;
429
429
  }
@@ -173,6 +173,10 @@ class Array
173
173
  reject {|e| e.__send__(key) == value}
174
174
  end
175
175
 
176
+ def arrange_by(*args, &block)
177
+ arrange(*args, &block)
178
+ end
179
+
176
180
  # concatenation
177
181
  # analogue to String#>>
178
182
  def >>(ary)
@@ -14,7 +14,6 @@ unless defined? RMTools::Iterators
14
14
  # => [[1, 2, 3], [3, 4, 6]]
15
15
  class Array
16
16
  alias :throw_no :method_missing
17
- alias :arrange_by :arrange
18
17
  RMTools::Iterators = %r{^(#{(my_methods(/_by$/)+%w{every no select reject partition find_all find sum foldr})*'|'})_([\w\d\_]+[!?]?)}
19
18
 
20
19
  def method_missing(method, *args, &block)
data/lib/rmtools/init.rb CHANGED
@@ -5,9 +5,9 @@ module RMTools
5
5
  VERSION = IO.read(File.join dir, '..', '..', 'Rakefile').match(/RMTOOLS_VERSION = '(.+?)'/)[1]
6
6
 
7
7
  require File.expand_path('require', dir)
8
- [ 'core', 'enumerable', 'text', 'time', 'functional',
9
- 'conversions', 'ip', 'lang', 'rand', 'console', 'b',
10
- 'fs', 'db', 'xml',
11
- '../rmtools.so'
8
+ %w[core enumerable text time functional
9
+ conversions ip lang rand console b
10
+ fs db xml
11
+ ../rmtools.so
12
12
  ].each {|file| RMTools::require file}
13
13
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rmtools
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.12
4
+ version: 1.2.13
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: