<commit_before>class Object
  # Start a Pry REPL.
  # This method differs from `Pry.start` in that it does not
  # support an options hash. Also, when no parameter is provided, the Pry
  # session will start on the implied receiver rather than on
  # top-level (as in the case of `Pry.start`).
  # It has two forms of invocation. In the first form no parameter
  # should be provided and it will start a pry session on the
  # receiver. In the second form it should be invoked without an
  # explicit receiver and one parameter; this will start a Pry
  # session on the parameter.
  # @param [Object, Binding] target The receiver of the Pry session.
  # @param [Symbol, Symbol] :quiet silences, anything else allows whereami.
  # @example First form
  #   "dummy".pry
  # @example Second form
  #    pry "dummy"
  # @example Start a Pry session on current self (whatever that is)
  #   pry
  # @example Start a Pry session on a binding without whereami
  #   binding.pry :quiet

  def pry(target=self, quiet = nil)
    if target == :quiet
      quiet, target = true, self
    else
      # Only :quiet makes it quiet, okay....
      quiet = quiet == :quiet ? true : false
    end

    Pry.start(target, :quiet => quiet)
  end

  # Return a binding object for the receiver.
  def __binding__
    if is_a?(Module)
      return class_eval "binding"
    end

    unless respond_to? :__binding_impl__
      begin
        instance_eval %{
          def __binding_impl__
            binding
          end
        }
      rescue TypeError
        self.class.class_eval %{
          def __binding_impl__
            binding
          end
        }
      end
    end<commit_msg>Switch Object#pry to a 'like' pass-through with temporary backwards compatibility.<commit_after>class Object
  # Start a Pry REPL.  This method only differs from Pry.start in that it
  # will accept a options hash now without the need for a binding and
  # will default to the binding `self`.  POSSIBLE DEPRICATION WARNING:
  # In the future the backwards compatibility with pry(binding) could be
  # removed so please properly use Object.pry or if you use pry(binding)
  # switch Pry.start(binding).

  # @param [Binding] the binding or options hash if no binding needed.
  # @param [Hash] the options hash.
  # @example First
  #   "dummy".pry
  # @example Second
  #    binding.pry
  # @example An example with options
  #   def my_method
  #     binding.pry :quiet => true
  #   end
  #   my_method()

  def pry(*args)
    if args.first.is_a?(Hash) || args.length == 0
      args.unshift(self)
    end
    
    Pry.start(*args)
  end

  # Return a binding object for the receiver.
  def __binding__
    if is_a?(Module)
      return class_eval "binding"
    end

    unless respond_to? :__binding_impl__
      begin
        instance_eval %{
          def __binding_impl__
            binding
          end
        }
      rescue TypeError
        self.class.class_eval %{
          def __binding_impl__
            binding
          end
        }
      end
    end
{'fraction_non_alphanumeric': 0.06985172981878089, 'fraction_numerical': 0.00032948929159802305, 'mean_word_length': 2.3509933774834435, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1750694', 'n_tokens_mistral': 904, 'n_tokens_neox': 882, 'n_words': 352}