From 4b98f7276c1f1c5ea7c39bae0e6abe542b0358b8 Mon Sep 17 00:00:00 2001 From: AntonioTerceiro Date: Tue, 3 Jun 2008 23:44:19 +0000 Subject: [PATCH] ActionItem392: backporting change f67b070facef6574df3c4386e3975242273fe456 from edge rails to support ruby 1.8.7 --- vendor/rails/activesupport/lib/active_support/core_ext/string/unicode.rb | 6 ++++++ 1 file changed, 6 insertions(+), 0 deletions(-) diff --git a/vendor/rails/activesupport/lib/active_support/core_ext/string/unicode.rb b/vendor/rails/activesupport/lib/active_support/core_ext/string/unicode.rb index dd19fe5..844f7de 100644 --- a/vendor/rails/activesupport/lib/active_support/core_ext/string/unicode.rb +++ b/vendor/rails/activesupport/lib/active_support/core_ext/string/unicode.rb @@ -3,6 +3,12 @@ module ActiveSupport #:nodoc: module String #:nodoc: # Define methods for handling unicode data. module Unicode + def self.included(base) + if '1.8.7'.respond_to?(:chars) + base.class_eval { remove_method :chars } + end + end + # +chars+ is a Unicode safe proxy for string methods. It creates and returns an instance of the # ActiveSupport::Multibyte::Chars class which encapsulates the original string. A Unicode safe version of all # the String methods are defined on this proxy class. Undefined methods are forwarded to String, so all of the -- libgit2 0.21.2