psych 2.0.11 → 2.0.12

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
  SHA1:
3
- metadata.gz: 2af495236ef2b2ab2ac26fdff1cd7fb85582213f
4
- data.tar.gz: 06fc3358b7e7a6cfc4190e6ade00b5519cd42611
3
+ metadata.gz: 38ed899f0b22c57d8a653dfb84f54a92d9c51ccd
4
+ data.tar.gz: b9fe79097035b8594dff79dacb4c85e55451be5f
5
5
  SHA512:
6
- metadata.gz: 10395b46073a828ffae197ac8c07375f5254f15ddfe3968f3ccb371002b7711e1df26a75cb0aedf88f5f26544b6aaca6d7e72cc0a52ced6f76f768dbd4e024f1
7
- data.tar.gz: 021960c8a5f0d0690312c6c9b07903a849e97be93bcfc013d449b75a010d8b633de5cbcb9a3f1b68fb07056f93daaf23bb9431f473310e4ed74c6516225b0858
6
+ metadata.gz: 705e8c7667b4a841aab3a868a3a77cb5e55eb0e6a3d76c1169eba8244ab8b5307c83f85d5fa546f4fdbbdf62ee1a82d2336a30a17443556875ffa8b29fd60bfc
7
+ data.tar.gz: 76f6c273cd9a0570fc64c1f0e789f907cb3ceeeabe6764549713a59fbbf06d83953afa4fcb53b6ca9527c724778b459b4bfac3310eb6e8ebe342b15e8589678e
@@ -1,3 +1,11 @@
1
+ Thu Jan 29 02:34:27 2015 Aaron Patterson <aaron@tenderlovemaking.com>
2
+
3
+ * ext/psych/lib/psych/visitors/to_ruby.rb: fix parsing hashes with
4
+ instance variables when it is referenced multiple times.
5
+ * ext/psych/lib/psych.rb: bump version
6
+ * ext/psych/psych.gemspec: bump version
7
+ * test/psych/test_hash.rb: test for fix
8
+
1
9
  Fri Jan 9 07:13:55 2015 Aaron Patterson <aaron@tenderlovemaking.com>
2
10
 
3
11
  * ext/psych/lib/psych/visitors/to_ruby.rb: call `allocate` on hash
@@ -217,7 +217,7 @@ require 'psych/class_loader'
217
217
 
218
218
  module Psych
219
219
  # The version is Psych you're using
220
- VERSION = '2.0.11'
220
+ VERSION = '2.0.12'
221
221
 
222
222
  # The version of libyaml Psych is using
223
223
  LIBYAML_VERSION = Psych.libyaml_version.join '.'
@@ -263,6 +263,7 @@ module Psych
263
263
 
264
264
  when /^!ruby\/hash-with-ivars(?::(.*))?$/
265
265
  hash = $1 ? resolve_class($1).allocate : {}
266
+ register o, hash
266
267
  o.children.each_slice(2) do |key, value|
267
268
  case key.value
268
269
  when 'elements'
@@ -23,6 +23,13 @@ module Psych
23
23
  @hash = { :a => 'b' }
24
24
  end
25
25
 
26
+ def test_referenced_hash_with_ivar
27
+ a = [1,2,3,4,5]
28
+ t1 = [HashWithCustomInit.new(a)]
29
+ t1 << t1.first
30
+ assert_cycle t1
31
+ end
32
+
26
33
  def test_custom_initialized
27
34
  a = [1,2,3,4,5]
28
35
  t1 = HashWithCustomInit.new(a)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: psych
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.11
4
+ version: 2.0.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aaron Patterson
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-01-20 00:00:00.000000000 Z
11
+ date: 2015-01-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rdoc