summaryrefslogtreecommitdiff
path: root/ext/psych/lib/psych/visitors
diff options
context:
space:
mode:
authortenderlove <tenderlove@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-04-24 20:35:20 +0000
committertenderlove <tenderlove@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-04-24 20:35:20 +0000
commit2d9c05441220ec5079925994b074380a78d50d8a (patch)
treeea7ef8ea7867ddbdfec787eba8a5c00e42ae3bf3 /ext/psych/lib/psych/visitors
parentd69c502c9f855a0215319516c4b0f594b4eb0606 (diff)
* ext/psych/lib/psych/deprecated.rb: adding support for deprecated
"add_private_type" function * ext/psych/lib/psych.rb: ditto * ext/psych/lib/psych/visitors/to_ruby.rb: ditto * test/psych/test_deprecated.rb: ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27480 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/psych/lib/psych/visitors')
-rw-r--r--ext/psych/lib/psych/visitors/to_ruby.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/psych/lib/psych/visitors/to_ruby.rb b/ext/psych/lib/psych/visitors/to_ruby.rb
index bbbe9a8366..e28ac7bf87 100644
--- a/ext/psych/lib/psych/visitors/to_ruby.rb
+++ b/ext/psych/lib/psych/visitors/to_ruby.rb
@@ -17,7 +17,7 @@ module Psych
return result if @domain_types.empty? || !target.tag
key = target.tag.sub(/^[!\/]*/, '').sub(/(,\d+)\//, '\1:')
- key = "tag:#{key}" unless key.start_with?('tag:')
+ key = "tag:#{key}" unless key =~ /^(tag:|x-private)/
if @domain_types.key? key
value, block = @domain_types[key]