encoding-kawai 0.4 → 0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/encoding-kawai.gemspec +1 -1
- data/lib/encoding-kawai/object.rb +2 -2
- data/spec/encoding-kawai_spec.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5fe8db4f9f19eaa55b5bfeb76ccbcc506e66a5e0
|
4
|
+
data.tar.gz: 55423af3f29c7c57b33ee3918b201a366292de73
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 774b3b7364dd5b8e295f25270f362dff06b40b1248fb9afb40f98c3108d59ba577934e37ee41ec0501eca53f225283d8013379d8e6ea0fb347b3ad7792c91329
|
7
|
+
data.tar.gz: aab3c0d90a8c49837717129b6707969a2689fdf67d28b4b89c08f6971abf582622b96904adfede1bccf736cd22349a7e28e0d2b907dfeb8f08c705224a58ad4c
|
data/encoding-kawai.gemspec
CHANGED
@@ -32,13 +32,13 @@ if RUBY_VERSION >= '1.9'
|
|
32
32
|
class Hash
|
33
33
|
def utf8!
|
34
34
|
{}.tap{|h|
|
35
|
-
keys.each { |k| h[(k.frozen? && !k.is_a?(Symbol)) ? k.dup.utf8! : k.utf8!] = self[k].utf8! }
|
35
|
+
keys.each { |k| h[(k.frozen? && !k.is_a?(Symbol) && !k.is_a?(Fixnum)) ? k.dup.utf8! : k.utf8!] = self[k].utf8! }
|
36
36
|
}
|
37
37
|
end
|
38
38
|
|
39
39
|
def binary!
|
40
40
|
{}.tap{|h|
|
41
|
-
keys.each { |k| h[(k.frozen? && !k.is_a?(Symbol)) ? k.dup.binary! : k.binary!] = self[k].binary! }
|
41
|
+
keys.each { |k| h[(k.frozen? && !k.is_a?(Symbol) && !k.is_a?(Fixnum)) ? k.dup.binary! : k.binary!] = self[k].binary! }
|
42
42
|
}
|
43
43
|
end
|
44
44
|
end
|
data/spec/encoding-kawai_spec.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
# -*- encoding : utf-8 -*-
|
2
2
|
require File.dirname(__FILE__) + '/spec_helper'
|
3
3
|
|
4
|
-
OBJS = ["bla", 'бла', ['bla', 'бла'], nil]
|
4
|
+
OBJS = ["bla", 'бла', ['bla', 'бла'], nil, {1=>2}]
|
5
5
|
H = {:bla => 'bla', 'бла' => 1, :url => nil, :x => [:a => "идф", :b => true]}
|
6
6
|
|
7
7
|
describe "encoding-kawai" do
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: encoding-kawai
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '0.
|
4
|
+
version: '0.5'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Makarchev K
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2015-05-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|