summaryrefslogtreecommitdiff
path: root/ext/psych/lib/psych/core_ext.rb
diff options
context:
space:
mode:
authorhsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-04-05 13:16:32 +0000
committerhsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-04-05 13:16:32 +0000
commit6d77e28763ed17f75edf3b4072701b4dbd7644bb (patch)
treee56f68d61222a1cf4bfc6a63aa640c6546a41b91 /ext/psych/lib/psych/core_ext.rb
parent4389ba641f89fe9d4e5c575442968d385c4183e8 (diff)
Import psych-3.0.0.beta1 from ruby/psych.
* Removed deprecated code. * Removed code related syck gem. * Fixed typos. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58256 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/psych/lib/psych/core_ext.rb')
-rw-r--r--ext/psych/lib/psych/core_ext.rb19
1 files changed, 1 insertions, 18 deletions
diff --git a/ext/psych/lib/psych/core_ext.rb b/ext/psych/lib/psych/core_ext.rb
index 1a98279afd..1232abf3d9 100644
--- a/ext/psych/lib/psych/core_ext.rb
+++ b/ext/psych/lib/psych/core_ext.rb
@@ -4,31 +4,14 @@ class Object
Psych.add_tag(url, self)
end
- # FIXME: rename this to "to_yaml" when syck is removed
-
###
# call-seq: to_yaml(options = {})
#
# Convert an object to YAML. See Psych.dump for more information on the
# available +options+.
- def psych_to_yaml options = {}
+ def to_yaml options = {}
Psych.dump self, options
end
- remove_method :to_yaml rescue nil
- alias :to_yaml :psych_to_yaml
-end
-
-class Module
- def psych_yaml_as url
- return if caller[0].end_with?('rubytypes.rb')
- if $VERBOSE
- warn "#{caller[0]}: yaml_as is deprecated, please use yaml_tag"
- end
- Psych.add_tag(url, self)
- end
-
- remove_method :yaml_as rescue nil
- alias :yaml_as :psych_yaml_as
end
if defined?(::IRB)