#!/usr/bin/env ruby
# -*- ruby -*-

# Copyright 2001 by Jim Weirich (jweirich@one.net).
# All rights reserved.

# Permission is granted for use, copying, modification, distribution,
# and distribution of modified versions of this work as long as the
# above copyright notice is included.

######################################################################
# Extensions to Enumerable
#
if ! Enumerable.instance_methods.member?("inject") then
  module Enumerable
    def inject (initial_value)
      result = initial_value
      each { |item| result = yield (result, item) }
      result
    end
  end
end


