Sha256: 6176637cafb9ea686c272232c96d78b28823b319bdbb322ceb9c65c653104250

Contents?: true

Size: 236 Bytes

Versions: 14

Compression:

Stored size: 236 Bytes

Contents

class Symbol
  # Standard in ruby 1.9. See official documentation[http://ruby-doc.org/core-1.9/classes/Symbol.html]
  def to_proc
    Proc.new { |*args| args.shift.__send__(self, *args) }
  end unless :to_proc.respond_to?(:to_proc)
end

Version data entries

14 entries across 14 versions & 2 rubygems

Version Path
marcandre-backports-1.0.1 lib/backports/symbol.rb
marcandre-backports-1.1.1 lib/backports/symbol.rb
marcandre-backports-1.2.0 lib/backports/symbol.rb
marcandre-backports-1.3.0 lib/backports/symbol.rb
marcandre-backports-1.3.1 lib/backports/symbol.rb
marcandre-backports-1.4.0 lib/backports/symbol.rb
marcandre-backports-1.5.0 lib/backports/symbol.rb
backports-1.1.0 lib/backports/symbol.rb
backports-1.0.0 lib/backports/symbol.rb
backports-1.1.1 lib/backports/symbol.rb
backports-1.3.0 lib/backports/symbol.rb
backports-1.2.0 lib/backports/symbol.rb
backports-1.5.0 lib/backports/symbol.rb
backports-1.3.1 lib/backports/symbol.rb