Class: Symbol

Inherits:
Object
  • Object
show all
Defined in:
lib/charlie/etc/monkey.rb

Instance Method Summary collapse

Instance Method Details

#[](*args) ⇒ Object

This function was added because :npoint just looks so much nicer than [:npoint,3]



105
106
107
# File 'lib/charlie/etc/monkey.rb', line 105

def [](*args)
  [self,*args]
end

#internObject



113
114
115
# File 'lib/charlie/etc/monkey.rb', line 113

def intern
  self
end

#to_procObject



109
110
111
# File 'lib/charlie/etc/monkey.rb', line 109

def to_proc
  Proc.new { |*args| args.shift.__send__(self, *args) }
end