def disable_singleton_method(name_or_sym)
      return unless singleton_methods.include?(name_or_sym.to_s)
      # dissociate the method from this instance
      method = self.method(name_or_sym.to_sym)
      method.unbind
      # JRuby unbind doesn't work in JRuby 1.1.6. In that case, redefine the singleton method to delegate
      # to the class instance method.
      if singleton_methods.include?(name_or_sym.to_s) then
        args = (1..method.arity).map { |argnum| "arg#{argnum}" }.join(', ')
        instance_eval "def #{name_or_sym}(#{args}); super; end"
      end
    end
def disable_singleton_method(name_or_sym)
      return unless singleton_methods.include?(name_or_sym.to_s)
      # dissociate the method from this instance
      method = self.method(name_or_sym.to_sym)
      method.unbind
      # JRuby unbind doesn't work in JRuby 1.1.6. In that case, redefine the singleton method to delegate
      # to the class instance method.
      if singleton_methods.include?(name_or_sym.to_s) then
        args = (1..method.arity).map { |argnum| "arg#{argnum}" }.join(', ')
        instance_eval "def #{name_or_sym}(#{args}); super; end"
      end
    end
Disables the given singleton attribute accessor method.

 @param [String, Symbol] name_or_sym the accessor method to disable